/*
 * Copyright (c) 2007, 2008, Oracle and/or its affiliates. All rights reserved.
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 *
 * This code is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License version 2 only, as
 * published by the Free Software Foundation.  Oracle designates this
 * particular file as subject to the "Classpath" exception as provided
 * by Oracle in the LICENSE file that accompanied this code.
 *
 * This code is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 * version 2 for more details (a copy is included in the LICENSE file that
 * accompanied this code).
 *
 * You should have received a copy of the GNU General Public License version
 * 2 along with this work; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
 * or visit www.oracle.com if you need additional information or have any
 * questions.
 */
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn rescale0 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   float4 offsets;
//   float4 scaleFactors;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   scaleFactors c0       1
//   offsets      c1       1
//   baseImage    s0       1
//

    ps_2_0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    texld r0, t0, s0
    mov r1, c0
    mad r0, r0, r1, c1
    mul r0, r0, v0
    mov oC0, r0

// approximately 5 instruction slots used (1 texture, 4 arithmetic)
#endif

const DWORD rescale0[] =
{
    0xffff0200, 0x0036fffe, 0x42415443, 0x0000001c, 0x000000a0, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x00000099, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00010002, 0x00060001,
    0x0000007c, 0x00000000, 0x0000008c, 0x00000002, 0x00020001, 0x0000007c,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x7366666f, 0x00737465, 0x00030001, 0x00040001,
    0x00000001, 0x00000000, 0x6c616373, 0x63614665, 0x73726f74, 0x5f737000,
    0x00305f32, 0x7263694d, 0x666f736f, 0x52282074, 0x4c482029, 0x53204c53,
    0x65646168, 0x6f432072, 0x6c69706d, 0x39207265, 0x2e39312e, 0x2e393439,
    0x31313132, 0xababab00, 0x0200001f, 0x80000000, 0xb0030000, 0x0200001f,
    0x80000000, 0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x03000042,
    0x800f0000, 0xb0e40000, 0xa0e40800, 0x02000001, 0x800f0001, 0xa0e40000,
    0x04000004, 0x800f0000, 0x80e40000, 0x80e40001, 0xa0e40001, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn rescale1 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   float4 offsets;
//   float4 scaleFactors;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   scaleFactors c0       1
//   offsets      c1       1
//   baseImage    s0       1
//

    ps_2_0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    texld r0, t0, s0
    rcp r1.w, r0.w
    mul r0.xyz, r0, r1.w
    mov r1, c0
    mad r0, r0, r1, c1
    mul r0.xyz, r0.w, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 8 instruction slots used (1 texture, 7 arithmetic)
#endif

const DWORD rescale1[] =
{
    0xffff0200, 0x0036fffe, 0x42415443, 0x0000001c, 0x000000a0, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x00000099, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00010002, 0x00060001,
    0x0000007c, 0x00000000, 0x0000008c, 0x00000002, 0x00020001, 0x0000007c,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x7366666f, 0x00737465, 0x00030001, 0x00040001,
    0x00000001, 0x00000000, 0x6c616373, 0x63614665, 0x73726f74, 0x5f737000,
    0x00305f32, 0x7263694d, 0x666f736f, 0x52282074, 0x4c482029, 0x53204c53,
    0x65646168, 0x6f432072, 0x6c69706d, 0x39207265, 0x2e39312e, 0x2e393439,
    0x31313132, 0xababab00, 0x0200001f, 0x80000000, 0xb0030000, 0x0200001f,
    0x80000000, 0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x03000042,
    0x800f0000, 0xb0e40000, 0xa0e40800, 0x02000006, 0x80080001, 0x80ff0000,
    0x03000005, 0x80070000, 0x80e40000, 0x80ff0001, 0x02000001, 0x800f0001,
    0xa0e40000, 0x04000004, 0x800f0000, 0x80e40000, 0x80e40001, 0xa0e40001,
    0x03000005, 0x80070000, 0x80ff0000, 0x80e40000, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
const DWORD *rescaleShaders[] =
{
    rescale0,
    rescale1,
};

#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn convolve0 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   float4 imgEdge;
//   float3 kernelVals[9];
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   imgEdge      c0       1
//   kernelVals   c1       9
//   baseImage    s0       1
//

    ps_2_0
    def c10, 0, 1, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    add r0.xy, t0, c2
    add r1.xy, t0, c1
    add r2.xy, t0, c3
    add r3.xy, t0, c4
    add r4.xy, t0, c5
    add r5.xy, t0, c6
    add r6.xy, t0, c7
    add r7.xy, t0, c8
    add r8.xy, t0, c9
    texld r0, r0, s0
    texld r1, r1, s0
    texld r2, r2, s0
    texld r9, t0, s0
    texld r3, r3, s0
    texld r4, r4, s0
    texld r5, r5, s0
    texld r6, r6, s0
    texld r7, r7, s0
    texld r8, r8, s0
    mul r0, r0, c2.z
    mad r0, c1.z, r1, r0
    mad r0, c3.z, r2, r0
    mad r0, c4.z, r3, r0
    mad r0, c5.z, r4, r0
    mad r0, c6.z, r5, r0
    mad r0, c7.z, r6, r0
    mad r0, c8.z, r7, r0
    mad r0, c9.z, r8, r0
    mul r0, r0, v0
    add r1.yw, -t0.y, c0
    add r1.xz, -t0.x, c0
    cmp r1.x, -r1.x, c10.x, c10.y
    cmp r1.y, -r1.y, c10.x, c10.y
    add r1.x, r1.x, r1.y
    cmp r1.x, -r1.x, c10.x, c10.y
    cmp r1.y, r1.z, c10.x, c10.y
    cmp r1.z, r1.w, c10.x, c10.y
    add r1.x, r1.x, r1.y
    cmp r1.x, -r1.x, c10.x, c10.y
    add r1.x, r1.z, r1.x
    cmp r0, -r1.x, r0, r9
    mov oC0, r0

// approximately 42 instruction slots used (10 texture, 32 arithmetic)
#endif

const DWORD convolve0[] =
{
    0xffff0200, 0x0039fffe, 0x42415443, 0x0000001c, 0x000000af, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a8, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00000002, 0x00020001,
    0x0000007c, 0x00000000, 0x0000008c, 0x00010002, 0x00060009, 0x00000098,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x45676d69, 0x00656764, 0x00030001, 0x00040001,
    0x00000001, 0x00000000, 0x6e72656b, 0x61566c65, 0xab00736c, 0x00030001,
    0x00030001, 0x00000009, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369,
    0x74666f73, 0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320,
    0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051,
    0xa00f000a, 0x00000000, 0x3f800000, 0x00000000, 0x00000000, 0x0200001f,
    0x80000000, 0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f,
    0x90000000, 0xa00f0800, 0x03000002, 0x80030000, 0xb0e40000, 0xa0e40002,
    0x03000002, 0x80030001, 0xb0e40000, 0xa0e40001, 0x03000002, 0x80030002,
    0xb0e40000, 0xa0e40003, 0x03000002, 0x80030003, 0xb0e40000, 0xa0e40004,
    0x03000002, 0x80030004, 0xb0e40000, 0xa0e40005, 0x03000002, 0x80030005,
    0xb0e40000, 0xa0e40006, 0x03000002, 0x80030006, 0xb0e40000, 0xa0e40007,
    0x03000002, 0x80030007, 0xb0e40000, 0xa0e40008, 0x03000002, 0x80030008,
    0xb0e40000, 0xa0e40009, 0x03000042, 0x800f0000, 0x80e40000, 0xa0e40800,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002,
    0x80e40002, 0xa0e40800, 0x03000042, 0x800f0009, 0xb0e40000, 0xa0e40800,
    0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800, 0x03000042, 0x800f0004,
    0x80e40004, 0xa0e40800, 0x03000042, 0x800f0005, 0x80e40005, 0xa0e40800,
    0x03000042, 0x800f0006, 0x80e40006, 0xa0e40800, 0x03000042, 0x800f0007,
    0x80e40007, 0xa0e40800, 0x03000042, 0x800f0008, 0x80e40008, 0xa0e40800,
    0x03000005, 0x800f0000, 0x80e40000, 0xa0aa0002, 0x04000004, 0x800f0000,
    0xa0aa0001, 0x80e40001, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0003,
    0x80e40002, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0004, 0x80e40003,
    0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0005, 0x80e40004, 0x80e40000,
    0x04000004, 0x800f0000, 0xa0aa0006, 0x80e40005, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa0007, 0x80e40006, 0x80e40000, 0x04000004, 0x800f0000,
    0xa0aa0008, 0x80e40007, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0009,
    0x80e40008, 0x80e40000, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000,
    0x03000002, 0x800a0001, 0xb1550000, 0xa0e40000, 0x03000002, 0x80050001,
    0xb1000000, 0xa0e40000, 0x04000058, 0x80010001, 0x81000001, 0xa000000a,
    0xa055000a, 0x04000058, 0x80020001, 0x81550001, 0xa000000a, 0xa055000a,
    0x03000002, 0x80010001, 0x80000001, 0x80550001, 0x04000058, 0x80010001,
    0x81000001, 0xa000000a, 0xa055000a, 0x04000058, 0x80020001, 0x80aa0001,
    0xa000000a, 0xa055000a, 0x04000058, 0x80040001, 0x80ff0001, 0xa000000a,
    0xa055000a, 0x03000002, 0x80010001, 0x80000001, 0x80550001, 0x04000058,
    0x80010001, 0x81000001, 0xa000000a, 0xa055000a, 0x03000002, 0x80010001,
    0x80aa0001, 0x80000001, 0x04000058, 0x800f0000, 0x81000001, 0x80e40000,
    0x80e40009, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn convolve1 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   float4 imgEdge;
//   float3 kernelVals[9];
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   imgEdge      c0       1
//   kernelVals   c1       9
//   baseImage    s0       1
//

    ps_2_0
    def c10, 0, 1, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    add r0.xy, t0, c2
    add r1.xy, t0, c1
    add r2.xy, t0, c3
    add r3.xy, t0, c4
    add r4.xy, t0, c5
    add r5.xy, t0, c6
    add r6.xy, t0, c7
    add r7.xy, t0, c8
    add r8.xy, t0, c9
    texld r0, r0, s0
    texld r1, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    texld r4, r4, s0
    texld r5, r5, s0
    texld r6, r6, s0
    texld r7, r7, s0
    texld r8, r8, s0
    mul r0, r0, c2.z
    mad r0, c1.z, r1, r0
    mad r0, c3.z, r2, r0
    mad r0, c4.z, r3, r0
    mad r0, c5.z, r4, r0
    mad r0, c6.z, r5, r0
    mad r0, c7.z, r6, r0
    mad r0, c8.z, r7, r0
    mad r0, c9.z, r8, r0
    mul r0, r0, v0
    add r1.yw, -t0.y, c0
    add r1.xz, -t0.x, c0
    cmp r1.x, -r1.x, c10.x, c10.y
    cmp r1.y, -r1.y, c10.x, c10.y
    add r1.x, r1.x, r1.y
    cmp r1.x, -r1.x, c10.x, c10.y
    cmp r1.y, r1.z, c10.x, c10.y
    cmp r1.z, r1.w, c10.x, c10.y
    add r1.x, r1.x, r1.y
    cmp r1.x, -r1.x, c10.x, c10.y
    add r1.x, r1.z, r1.x
    cmp r0, -r1.x, r0, c10.x
    mov oC0, r0

// approximately 41 instruction slots used (9 texture, 32 arithmetic)
#endif

const DWORD convolve1[] =
{
    0xffff0200, 0x0039fffe, 0x42415443, 0x0000001c, 0x000000af, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a8, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00000002, 0x00020001,
    0x0000007c, 0x00000000, 0x0000008c, 0x00010002, 0x00060009, 0x00000098,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x45676d69, 0x00656764, 0x00030001, 0x00040001,
    0x00000001, 0x00000000, 0x6e72656b, 0x61566c65, 0xab00736c, 0x00030001,
    0x00030001, 0x00000009, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369,
    0x74666f73, 0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320,
    0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051,
    0xa00f000a, 0x00000000, 0x3f800000, 0x00000000, 0x00000000, 0x0200001f,
    0x80000000, 0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f,
    0x90000000, 0xa00f0800, 0x03000002, 0x80030000, 0xb0e40000, 0xa0e40002,
    0x03000002, 0x80030001, 0xb0e40000, 0xa0e40001, 0x03000002, 0x80030002,
    0xb0e40000, 0xa0e40003, 0x03000002, 0x80030003, 0xb0e40000, 0xa0e40004,
    0x03000002, 0x80030004, 0xb0e40000, 0xa0e40005, 0x03000002, 0x80030005,
    0xb0e40000, 0xa0e40006, 0x03000002, 0x80030006, 0xb0e40000, 0xa0e40007,
    0x03000002, 0x80030007, 0xb0e40000, 0xa0e40008, 0x03000002, 0x80030008,
    0xb0e40000, 0xa0e40009, 0x03000042, 0x800f0000, 0x80e40000, 0xa0e40800,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002,
    0x80e40002, 0xa0e40800, 0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800,
    0x03000042, 0x800f0004, 0x80e40004, 0xa0e40800, 0x03000042, 0x800f0005,
    0x80e40005, 0xa0e40800, 0x03000042, 0x800f0006, 0x80e40006, 0xa0e40800,
    0x03000042, 0x800f0007, 0x80e40007, 0xa0e40800, 0x03000042, 0x800f0008,
    0x80e40008, 0xa0e40800, 0x03000005, 0x800f0000, 0x80e40000, 0xa0aa0002,
    0x04000004, 0x800f0000, 0xa0aa0001, 0x80e40001, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa0003, 0x80e40002, 0x80e40000, 0x04000004, 0x800f0000,
    0xa0aa0004, 0x80e40003, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0005,
    0x80e40004, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0006, 0x80e40005,
    0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0007, 0x80e40006, 0x80e40000,
    0x04000004, 0x800f0000, 0xa0aa0008, 0x80e40007, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa0009, 0x80e40008, 0x80e40000, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x03000002, 0x800a0001, 0xb1550000, 0xa0e40000,
    0x03000002, 0x80050001, 0xb1000000, 0xa0e40000, 0x04000058, 0x80010001,
    0x81000001, 0xa000000a, 0xa055000a, 0x04000058, 0x80020001, 0x81550001,
    0xa000000a, 0xa055000a, 0x03000002, 0x80010001, 0x80000001, 0x80550001,
    0x04000058, 0x80010001, 0x81000001, 0xa000000a, 0xa055000a, 0x04000058,
    0x80020001, 0x80aa0001, 0xa000000a, 0xa055000a, 0x04000058, 0x80040001,
    0x80ff0001, 0xa000000a, 0xa055000a, 0x03000002, 0x80010001, 0x80000001,
    0x80550001, 0x04000058, 0x80010001, 0x81000001, 0xa000000a, 0xa055000a,
    0x03000002, 0x80010001, 0x80aa0001, 0x80000001, 0x04000058, 0x800f0000,
    0x81000001, 0x80e40000, 0xa000000a, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn convolve2 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   float4 imgEdge;
//   float3 kernelVals[25];
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   imgEdge      c0       1
//   kernelVals   c1      25
//   baseImage    s0       1
//

    ps_2_0
    def c26, 0, 1, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    add r0.xy, t0, c2
    add r1.xy, t0, c1
    add r2.xy, t0, c3
    add r3.xy, t0, c4
    add r4.xy, t0, c5
    add r5.xy, t0, c6
    add r6.xy, t0, c7
    add r7.xy, t0, c8
    add r8.xy, t0, c9
    texld r0, r0, s0
    texld r1, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    texld r4, r4, s0
    texld r5, r5, s0
    texld r6, r6, s0
    texld r7, r7, s0
    texld r8, r8, s0
    mul r0, r0, c2.z
    mad r0, c1.z, r1, r0
    mad r0, c3.z, r2, r0
    mad r0, c4.z, r3, r0
    mad r0, c5.z, r4, r0
    mad r0, c6.z, r5, r0
    mad r0, c7.z, r6, r0
    mad r0, c8.z, r7, r0
    mad r0, c9.z, r8, r0
    add r1.xy, t0, c10
    add r2.xy, t0, c11
    add r3.xy, t0, c12
    add r4.xy, t0, c13
    add r5.xy, t0, c14
    add r6.xy, t0, c15
    add r7.xy, t0, c16
    add r8.xy, t0, c17
    add r9.xy, t0, c18
    texld r1, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    texld r4, r4, s0
    texld r5, r5, s0
    texld r6, r6, s0
    texld r7, r7, s0
    texld r8, r8, s0
    texld r9, r9, s0
    mad r0, c10.z, r1, r0
    mad r0, c11.z, r2, r0
    mad r0, c12.z, r3, r0
    mad r0, c13.z, r4, r0
    mad r0, c14.z, r5, r0
    mad r0, c15.z, r6, r0
    mad r0, c16.z, r7, r0
    mad r0, c17.z, r8, r0
    mad r0, c18.z, r9, r0
    add r1.xy, t0, c19
    add r2.xy, t0, c20
    add r3.xy, t0, c21
    add r4.xy, t0, c22
    add r5.xy, t0, c23
    add r6.xy, t0, c24
    add r7.xy, t0, c25
    texld r1, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    texld r4, r4, s0
    texld r5, r5, s0
    texld r6, r6, s0
    texld r7, r7, s0
    texld r8, t0, s0
    mad r0, c19.z, r1, r0
    mad r0, c20.z, r2, r0
    mad r0, c21.z, r3, r0
    mad r0, c22.z, r4, r0
    mad r0, c23.z, r5, r0
    mad r0, c24.z, r6, r0
    mad r0, c25.z, r7, r0
    mul r0, r0, v0
    add r1.yw, -t0.y, c0
    add r1.xz, -t0.x, c0
    cmp r1.x, -r1.x, c26.x, c26.y
    cmp r1.y, -r1.y, c26.x, c26.y
    add r1.x, r1.x, r1.y
    cmp r1.x, -r1.x, c26.x, c26.y
    cmp r1.y, r1.z, c26.x, c26.y
    cmp r1.z, r1.w, c26.x, c26.y
    add r1.x, r1.x, r1.y
    cmp r1.x, -r1.x, c26.x, c26.y
    add r1.x, r1.z, r1.x
    cmp r0, -r1.x, r0, r8
    mov oC0, r0

// approximately 90 instruction slots used (26 texture, 64 arithmetic)
#endif

const DWORD convolve2[] =
{
    0xffff0200, 0x0039fffe, 0x42415443, 0x0000001c, 0x000000af, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a8, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00000002, 0x00020001,
    0x0000007c, 0x00000000, 0x0000008c, 0x00010002, 0x00060019, 0x00000098,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x45676d69, 0x00656764, 0x00030001, 0x00040001,
    0x00000001, 0x00000000, 0x6e72656b, 0x61566c65, 0xab00736c, 0x00030001,
    0x00030001, 0x00000019, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369,
    0x74666f73, 0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320,
    0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051,
    0xa00f001a, 0x00000000, 0x3f800000, 0x00000000, 0x00000000, 0x0200001f,
    0x80000000, 0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f,
    0x90000000, 0xa00f0800, 0x03000002, 0x80030000, 0xb0e40000, 0xa0e40002,
    0x03000002, 0x80030001, 0xb0e40000, 0xa0e40001, 0x03000002, 0x80030002,
    0xb0e40000, 0xa0e40003, 0x03000002, 0x80030003, 0xb0e40000, 0xa0e40004,
    0x03000002, 0x80030004, 0xb0e40000, 0xa0e40005, 0x03000002, 0x80030005,
    0xb0e40000, 0xa0e40006, 0x03000002, 0x80030006, 0xb0e40000, 0xa0e40007,
    0x03000002, 0x80030007, 0xb0e40000, 0xa0e40008, 0x03000002, 0x80030008,
    0xb0e40000, 0xa0e40009, 0x03000042, 0x800f0000, 0x80e40000, 0xa0e40800,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002,
    0x80e40002, 0xa0e40800, 0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800,
    0x03000042, 0x800f0004, 0x80e40004, 0xa0e40800, 0x03000042, 0x800f0005,
    0x80e40005, 0xa0e40800, 0x03000042, 0x800f0006, 0x80e40006, 0xa0e40800,
    0x03000042, 0x800f0007, 0x80e40007, 0xa0e40800, 0x03000042, 0x800f0008,
    0x80e40008, 0xa0e40800, 0x03000005, 0x800f0000, 0x80e40000, 0xa0aa0002,
    0x04000004, 0x800f0000, 0xa0aa0001, 0x80e40001, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa0003, 0x80e40002, 0x80e40000, 0x04000004, 0x800f0000,
    0xa0aa0004, 0x80e40003, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0005,
    0x80e40004, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0006, 0x80e40005,
    0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0007, 0x80e40006, 0x80e40000,
    0x04000004, 0x800f0000, 0xa0aa0008, 0x80e40007, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa0009, 0x80e40008, 0x80e40000, 0x03000002, 0x80030001,
    0xb0e40000, 0xa0e4000a, 0x03000002, 0x80030002, 0xb0e40000, 0xa0e4000b,
    0x03000002, 0x80030003, 0xb0e40000, 0xa0e4000c, 0x03000002, 0x80030004,
    0xb0e40000, 0xa0e4000d, 0x03000002, 0x80030005, 0xb0e40000, 0xa0e4000e,
    0x03000002, 0x80030006, 0xb0e40000, 0xa0e4000f, 0x03000002, 0x80030007,
    0xb0e40000, 0xa0e40010, 0x03000002, 0x80030008, 0xb0e40000, 0xa0e40011,
    0x03000002, 0x80030009, 0xb0e40000, 0xa0e40012, 0x03000042, 0x800f0001,
    0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800,
    0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800, 0x03000042, 0x800f0004,
    0x80e40004, 0xa0e40800, 0x03000042, 0x800f0005, 0x80e40005, 0xa0e40800,
    0x03000042, 0x800f0006, 0x80e40006, 0xa0e40800, 0x03000042, 0x800f0007,
    0x80e40007, 0xa0e40800, 0x03000042, 0x800f0008, 0x80e40008, 0xa0e40800,
    0x03000042, 0x800f0009, 0x80e40009, 0xa0e40800, 0x04000004, 0x800f0000,
    0xa0aa000a, 0x80e40001, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa000b,
    0x80e40002, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa000c, 0x80e40003,
    0x80e40000, 0x04000004, 0x800f0000, 0xa0aa000d, 0x80e40004, 0x80e40000,
    0x04000004, 0x800f0000, 0xa0aa000e, 0x80e40005, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa000f, 0x80e40006, 0x80e40000, 0x04000004, 0x800f0000,
    0xa0aa0010, 0x80e40007, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0011,
    0x80e40008, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0012, 0x80e40009,
    0x80e40000, 0x03000002, 0x80030001, 0xb0e40000, 0xa0e40013, 0x03000002,
    0x80030002, 0xb0e40000, 0xa0e40014, 0x03000002, 0x80030003, 0xb0e40000,
    0xa0e40015, 0x03000002, 0x80030004, 0xb0e40000, 0xa0e40016, 0x03000002,
    0x80030005, 0xb0e40000, 0xa0e40017, 0x03000002, 0x80030006, 0xb0e40000,
    0xa0e40018, 0x03000002, 0x80030007, 0xb0e40000, 0xa0e40019, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002, 0x80e40002,
    0xa0e40800, 0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800, 0x03000042,
    0x800f0004, 0x80e40004, 0xa0e40800, 0x03000042, 0x800f0005, 0x80e40005,
    0xa0e40800, 0x03000042, 0x800f0006, 0x80e40006, 0xa0e40800, 0x03000042,
    0x800f0007, 0x80e40007, 0xa0e40800, 0x03000042, 0x800f0008, 0xb0e40000,
    0xa0e40800, 0x04000004, 0x800f0000, 0xa0aa0013, 0x80e40001, 0x80e40000,
    0x04000004, 0x800f0000, 0xa0aa0014, 0x80e40002, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa0015, 0x80e40003, 0x80e40000, 0x04000004, 0x800f0000,
    0xa0aa0016, 0x80e40004, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0017,
    0x80e40005, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0018, 0x80e40006,
    0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0019, 0x80e40007, 0x80e40000,
    0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x03000002, 0x800a0001,
    0xb1550000, 0xa0e40000, 0x03000002, 0x80050001, 0xb1000000, 0xa0e40000,
    0x04000058, 0x80010001, 0x81000001, 0xa000001a, 0xa055001a, 0x04000058,
    0x80020001, 0x81550001, 0xa000001a, 0xa055001a, 0x03000002, 0x80010001,
    0x80000001, 0x80550001, 0x04000058, 0x80010001, 0x81000001, 0xa000001a,
    0xa055001a, 0x04000058, 0x80020001, 0x80aa0001, 0xa000001a, 0xa055001a,
    0x04000058, 0x80040001, 0x80ff0001, 0xa000001a, 0xa055001a, 0x03000002,
    0x80010001, 0x80000001, 0x80550001, 0x04000058, 0x80010001, 0x81000001,
    0xa000001a, 0xa055001a, 0x03000002, 0x80010001, 0x80aa0001, 0x80000001,
    0x04000058, 0x800f0000, 0x81000001, 0x80e40000, 0x80e40008, 0x02000001,
    0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn convolve3 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   float4 imgEdge;
//   float3 kernelVals[25];
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   imgEdge      c0       1
//   kernelVals   c1      25
//   baseImage    s0       1
//

    ps_2_0
    def c26, 0, 1, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    add r0.xy, t0, c2
    add r1.xy, t0, c1
    add r2.xy, t0, c3
    add r3.xy, t0, c4
    add r4.xy, t0, c5
    add r5.xy, t0, c6
    add r6.xy, t0, c7
    add r7.xy, t0, c8
    add r8.xy, t0, c9
    texld r0, r0, s0
    texld r1, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    texld r4, r4, s0
    texld r5, r5, s0
    texld r6, r6, s0
    texld r7, r7, s0
    texld r8, r8, s0
    mul r0, r0, c2.z
    mad r0, c1.z, r1, r0
    mad r0, c3.z, r2, r0
    mad r0, c4.z, r3, r0
    mad r0, c5.z, r4, r0
    mad r0, c6.z, r5, r0
    mad r0, c7.z, r6, r0
    mad r0, c8.z, r7, r0
    mad r0, c9.z, r8, r0
    add r1.xy, t0, c10
    add r2.xy, t0, c11
    add r3.xy, t0, c12
    add r4.xy, t0, c13
    add r5.xy, t0, c14
    add r6.xy, t0, c15
    add r7.xy, t0, c16
    add r8.xy, t0, c17
    add r9.xy, t0, c18
    texld r1, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    texld r4, r4, s0
    texld r5, r5, s0
    texld r6, r6, s0
    texld r7, r7, s0
    texld r8, r8, s0
    texld r9, r9, s0
    mad r0, c10.z, r1, r0
    mad r0, c11.z, r2, r0
    mad r0, c12.z, r3, r0
    mad r0, c13.z, r4, r0
    mad r0, c14.z, r5, r0
    mad r0, c15.z, r6, r0
    mad r0, c16.z, r7, r0
    mad r0, c17.z, r8, r0
    mad r0, c18.z, r9, r0
    add r1.xy, t0, c19
    add r2.xy, t0, c20
    add r3.xy, t0, c21
    add r4.xy, t0, c22
    add r5.xy, t0, c23
    add r6.xy, t0, c24
    add r7.xy, t0, c25
    texld r1, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    texld r4, r4, s0
    texld r5, r5, s0
    texld r6, r6, s0
    texld r7, r7, s0
    mad r0, c19.z, r1, r0
    mad r0, c20.z, r2, r0
    mad r0, c21.z, r3, r0
    mad r0, c22.z, r4, r0
    mad r0, c23.z, r5, r0
    mad r0, c24.z, r6, r0
    mad r0, c25.z, r7, r0
    mul r0, r0, v0
    add r1.yw, -t0.y, c0
    add r1.xz, -t0.x, c0
    cmp r1.x, -r1.x, c26.x, c26.y
    cmp r1.y, -r1.y, c26.x, c26.y
    add r1.x, r1.x, r1.y
    cmp r1.x, -r1.x, c26.x, c26.y
    cmp r1.y, r1.z, c26.x, c26.y
    cmp r1.z, r1.w, c26.x, c26.y
    add r1.x, r1.x, r1.y
    cmp r1.x, -r1.x, c26.x, c26.y
    add r1.x, r1.z, r1.x
    cmp r0, -r1.x, r0, c26.x
    mov oC0, r0

// approximately 89 instruction slots used (25 texture, 64 arithmetic)
#endif

const DWORD convolve3[] =
{
    0xffff0200, 0x0039fffe, 0x42415443, 0x0000001c, 0x000000af, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a8, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00000002, 0x00020001,
    0x0000007c, 0x00000000, 0x0000008c, 0x00010002, 0x00060019, 0x00000098,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x45676d69, 0x00656764, 0x00030001, 0x00040001,
    0x00000001, 0x00000000, 0x6e72656b, 0x61566c65, 0xab00736c, 0x00030001,
    0x00030001, 0x00000019, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369,
    0x74666f73, 0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320,
    0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051,
    0xa00f001a, 0x00000000, 0x3f800000, 0x00000000, 0x00000000, 0x0200001f,
    0x80000000, 0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f,
    0x90000000, 0xa00f0800, 0x03000002, 0x80030000, 0xb0e40000, 0xa0e40002,
    0x03000002, 0x80030001, 0xb0e40000, 0xa0e40001, 0x03000002, 0x80030002,
    0xb0e40000, 0xa0e40003, 0x03000002, 0x80030003, 0xb0e40000, 0xa0e40004,
    0x03000002, 0x80030004, 0xb0e40000, 0xa0e40005, 0x03000002, 0x80030005,
    0xb0e40000, 0xa0e40006, 0x03000002, 0x80030006, 0xb0e40000, 0xa0e40007,
    0x03000002, 0x80030007, 0xb0e40000, 0xa0e40008, 0x03000002, 0x80030008,
    0xb0e40000, 0xa0e40009, 0x03000042, 0x800f0000, 0x80e40000, 0xa0e40800,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002,
    0x80e40002, 0xa0e40800, 0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800,
    0x03000042, 0x800f0004, 0x80e40004, 0xa0e40800, 0x03000042, 0x800f0005,
    0x80e40005, 0xa0e40800, 0x03000042, 0x800f0006, 0x80e40006, 0xa0e40800,
    0x03000042, 0x800f0007, 0x80e40007, 0xa0e40800, 0x03000042, 0x800f0008,
    0x80e40008, 0xa0e40800, 0x03000005, 0x800f0000, 0x80e40000, 0xa0aa0002,
    0x04000004, 0x800f0000, 0xa0aa0001, 0x80e40001, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa0003, 0x80e40002, 0x80e40000, 0x04000004, 0x800f0000,
    0xa0aa0004, 0x80e40003, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0005,
    0x80e40004, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0006, 0x80e40005,
    0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0007, 0x80e40006, 0x80e40000,
    0x04000004, 0x800f0000, 0xa0aa0008, 0x80e40007, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa0009, 0x80e40008, 0x80e40000, 0x03000002, 0x80030001,
    0xb0e40000, 0xa0e4000a, 0x03000002, 0x80030002, 0xb0e40000, 0xa0e4000b,
    0x03000002, 0x80030003, 0xb0e40000, 0xa0e4000c, 0x03000002, 0x80030004,
    0xb0e40000, 0xa0e4000d, 0x03000002, 0x80030005, 0xb0e40000, 0xa0e4000e,
    0x03000002, 0x80030006, 0xb0e40000, 0xa0e4000f, 0x03000002, 0x80030007,
    0xb0e40000, 0xa0e40010, 0x03000002, 0x80030008, 0xb0e40000, 0xa0e40011,
    0x03000002, 0x80030009, 0xb0e40000, 0xa0e40012, 0x03000042, 0x800f0001,
    0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800,
    0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800, 0x03000042, 0x800f0004,
    0x80e40004, 0xa0e40800, 0x03000042, 0x800f0005, 0x80e40005, 0xa0e40800,
    0x03000042, 0x800f0006, 0x80e40006, 0xa0e40800, 0x03000042, 0x800f0007,
    0x80e40007, 0xa0e40800, 0x03000042, 0x800f0008, 0x80e40008, 0xa0e40800,
    0x03000042, 0x800f0009, 0x80e40009, 0xa0e40800, 0x04000004, 0x800f0000,
    0xa0aa000a, 0x80e40001, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa000b,
    0x80e40002, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa000c, 0x80e40003,
    0x80e40000, 0x04000004, 0x800f0000, 0xa0aa000d, 0x80e40004, 0x80e40000,
    0x04000004, 0x800f0000, 0xa0aa000e, 0x80e40005, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa000f, 0x80e40006, 0x80e40000, 0x04000004, 0x800f0000,
    0xa0aa0010, 0x80e40007, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0011,
    0x80e40008, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0012, 0x80e40009,
    0x80e40000, 0x03000002, 0x80030001, 0xb0e40000, 0xa0e40013, 0x03000002,
    0x80030002, 0xb0e40000, 0xa0e40014, 0x03000002, 0x80030003, 0xb0e40000,
    0xa0e40015, 0x03000002, 0x80030004, 0xb0e40000, 0xa0e40016, 0x03000002,
    0x80030005, 0xb0e40000, 0xa0e40017, 0x03000002, 0x80030006, 0xb0e40000,
    0xa0e40018, 0x03000002, 0x80030007, 0xb0e40000, 0xa0e40019, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002, 0x80e40002,
    0xa0e40800, 0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800, 0x03000042,
    0x800f0004, 0x80e40004, 0xa0e40800, 0x03000042, 0x800f0005, 0x80e40005,
    0xa0e40800, 0x03000042, 0x800f0006, 0x80e40006, 0xa0e40800, 0x03000042,
    0x800f0007, 0x80e40007, 0xa0e40800, 0x04000004, 0x800f0000, 0xa0aa0013,
    0x80e40001, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0014, 0x80e40002,
    0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0015, 0x80e40003, 0x80e40000,
    0x04000004, 0x800f0000, 0xa0aa0016, 0x80e40004, 0x80e40000, 0x04000004,
    0x800f0000, 0xa0aa0017, 0x80e40005, 0x80e40000, 0x04000004, 0x800f0000,
    0xa0aa0018, 0x80e40006, 0x80e40000, 0x04000004, 0x800f0000, 0xa0aa0019,
    0x80e40007, 0x80e40000, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000,
    0x03000002, 0x800a0001, 0xb1550000, 0xa0e40000, 0x03000002, 0x80050001,
    0xb1000000, 0xa0e40000, 0x04000058, 0x80010001, 0x81000001, 0xa000001a,
    0xa055001a, 0x04000058, 0x80020001, 0x81550001, 0xa000001a, 0xa055001a,
    0x03000002, 0x80010001, 0x80000001, 0x80550001, 0x04000058, 0x80010001,
    0x81000001, 0xa000001a, 0xa055001a, 0x04000058, 0x80020001, 0x80aa0001,
    0xa000001a, 0xa055001a, 0x04000058, 0x80040001, 0x80ff0001, 0xa000001a,
    0xa055001a, 0x03000002, 0x80010001, 0x80000001, 0x80550001, 0x04000058,
    0x80010001, 0x81000001, 0xa000001a, 0xa055001a, 0x03000002, 0x80010001,
    0x80aa0001, 0x80000001, 0x04000058, 0x800f0000, 0x81000001, 0x80e40000,
    0xa000001a, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
const DWORD *convolveShaders[] =
{
    convolve0,
    convolve1,
    convolve2,
    convolve3,
};

#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn lookup0 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   sampler2D lookupTable;
//   float4 offset;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   offset       c0       1
//   baseImage    s0       1
//   lookupTable  s1       1
//

    ps_2_0
    def c1, 0.125, 0.375, 0.625, 0.875
    dcl t0.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    texld r0, t0, s0
    mov r1.y, c1.x
    add r0, r0, -c0
    mov r1.x, r0.x
    mov r0.x, r0.y
    mov r0.y, c1.y
    mov r2.x, r0.z
    mov r3.x, r0.w
    mov r2.y, c1.z
    mov r3.y, c1.w
    texld r1, r1, s1
    texld r0, r0, s1
    texld r2, r2, s1
    texld r3, r3, s1
    mov r1.y, r0.x
    mov r1.z, r2.x
    mov r1.w, r3.x
    mul r0, r1, v0
    mov oC0, r0

// approximately 19 instruction slots used (5 texture, 14 arithmetic)
#endif

const DWORD lookup0[] =
{
    0xffff0200, 0x0035fffe, 0x42415443, 0x0000001c, 0x0000009f, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x00000098, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00010003, 0x00060001,
    0x00000064, 0x00000000, 0x00000080, 0x00000002, 0x00020001, 0x00000088,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x6b6f6f6c, 0x61547075, 0x00656c62, 0x7366666f,
    0xab007465, 0x00030001, 0x00040001, 0x00000001, 0x00000000, 0x325f7370,
    0x4d00305f, 0x6f726369, 0x74666f73, 0x29522820, 0x534c4820, 0x6853204c,
    0x72656461, 0x6d6f4320, 0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934,
    0x00313131, 0x05000051, 0xa00f0001, 0x3e000000, 0x3ec00000, 0x3f200000,
    0x3f600000, 0x0200001f, 0x80000000, 0xb0030000, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x03000042, 0x800f0000, 0xb0e40000, 0xa0e40800, 0x02000001,
    0x80020001, 0xa0000001, 0x03000002, 0x800f0000, 0x80e40000, 0xa1e40000,
    0x02000001, 0x80010001, 0x80000000, 0x02000001, 0x80010000, 0x80550000,
    0x02000001, 0x80020000, 0xa0550001, 0x02000001, 0x80010002, 0x80aa0000,
    0x02000001, 0x80010003, 0x80ff0000, 0x02000001, 0x80020002, 0xa0aa0001,
    0x02000001, 0x80020003, 0xa0ff0001, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0000, 0x80e40000, 0xa0e40801, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0003, 0x80e40003,
    0xa0e40801, 0x02000001, 0x80020001, 0x80000000, 0x02000001, 0x80040001,
    0x80000002, 0x02000001, 0x80080001, 0x80000003, 0x03000005, 0x800f0000,
    0x80e40001, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn lookup1 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   sampler2D lookupTable;
//   float4 offset;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   offset       c0       1
//   baseImage    s0       1
//   lookupTable  s1       1
//

    ps_2_0
    def c1, 0.125, 0.375, 0.625, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    texld r0, t0, s0
    mov r1.y, c1.x
    add r2.xyz, r0, -c0
    mov r1.x, r2.x
    mov r2.x, r2.y
    mov r3.x, r2.z
    mov r2.y, c1.y
    mov r3.y, c1.z
    texld r1, r1, s1
    texld r2, r2, s1
    texld r3, r3, s1
    mov r0.x, r1.x
    mov r0.y, r2.x
    mov r0.z, r3.x
    mul r0, r0, v0
    mov oC0, r0

// approximately 16 instruction slots used (4 texture, 12 arithmetic)
#endif

const DWORD lookup1[] =
{
    0xffff0200, 0x0035fffe, 0x42415443, 0x0000001c, 0x0000009f, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x00000098, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00010003, 0x00060001,
    0x00000064, 0x00000000, 0x00000080, 0x00000002, 0x00020001, 0x00000088,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x6b6f6f6c, 0x61547075, 0x00656c62, 0x7366666f,
    0xab007465, 0x00030001, 0x00040001, 0x00000001, 0x00000000, 0x325f7370,
    0x4d00305f, 0x6f726369, 0x74666f73, 0x29522820, 0x534c4820, 0x6853204c,
    0x72656461, 0x6d6f4320, 0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934,
    0x00313131, 0x05000051, 0xa00f0001, 0x3e000000, 0x3ec00000, 0x3f200000,
    0x00000000, 0x0200001f, 0x80000000, 0xb0030000, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x03000042, 0x800f0000, 0xb0e40000, 0xa0e40800, 0x02000001,
    0x80020001, 0xa0000001, 0x03000002, 0x80070002, 0x80e40000, 0xa1e40000,
    0x02000001, 0x80010001, 0x80000002, 0x02000001, 0x80010002, 0x80550002,
    0x02000001, 0x80010003, 0x80aa0002, 0x02000001, 0x80020002, 0xa0550001,
    0x02000001, 0x80020003, 0xa0aa0001, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042,
    0x800f0003, 0x80e40003, 0xa0e40801, 0x02000001, 0x80010000, 0x80000001,
    0x02000001, 0x80020000, 0x80000002, 0x02000001, 0x80040000, 0x80000003,
    0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800,
    0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn lookup2 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   sampler2D lookupTable;
//   float4 offset;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   offset       c0       1
//   baseImage    s0       1
//   lookupTable  s1       1
//

    ps_2_0
    def c1, 0.125, 0.375, 0.625, 0.875
    dcl t0.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    texld r0, t0, s0
    mov r1.y, c1.x
    rcp r1.z, r0.w
    mul r0.xyz, r0, r1.z
    add r0, r0, -c0
    mov r1.x, r0.x
    mov r0.x, r0.y
    mov r0.y, c1.y
    mov r2.x, r0.z
    mov r3.x, r0.w
    mov r2.y, c1.z
    mov r3.y, c1.w
    texld r1, r1, s1
    texld r0, r0, s1
    texld r2, r2, s1
    texld r3, r3, s1
    mov r1.y, r0.x
    mov r1.z, r2.x
    mul r0.xyz, r3.x, r1
    mov r0.w, r3.x
    mul r0, r0, v0
    mov oC0, r0

// approximately 22 instruction slots used (5 texture, 17 arithmetic)
#endif

const DWORD lookup2[] =
{
    0xffff0200, 0x0035fffe, 0x42415443, 0x0000001c, 0x0000009f, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x00000098, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00010003, 0x00060001,
    0x00000064, 0x00000000, 0x00000080, 0x00000002, 0x00020001, 0x00000088,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x6b6f6f6c, 0x61547075, 0x00656c62, 0x7366666f,
    0xab007465, 0x00030001, 0x00040001, 0x00000001, 0x00000000, 0x325f7370,
    0x4d00305f, 0x6f726369, 0x74666f73, 0x29522820, 0x534c4820, 0x6853204c,
    0x72656461, 0x6d6f4320, 0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934,
    0x00313131, 0x05000051, 0xa00f0001, 0x3e000000, 0x3ec00000, 0x3f200000,
    0x3f600000, 0x0200001f, 0x80000000, 0xb0030000, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x03000042, 0x800f0000, 0xb0e40000, 0xa0e40800, 0x02000001,
    0x80020001, 0xa0000001, 0x02000006, 0x80040001, 0x80ff0000, 0x03000005,
    0x80070000, 0x80e40000, 0x80aa0001, 0x03000002, 0x800f0000, 0x80e40000,
    0xa1e40000, 0x02000001, 0x80010001, 0x80000000, 0x02000001, 0x80010000,
    0x80550000, 0x02000001, 0x80020000, 0xa0550001, 0x02000001, 0x80010002,
    0x80aa0000, 0x02000001, 0x80010003, 0x80ff0000, 0x02000001, 0x80020002,
    0xa0aa0001, 0x02000001, 0x80020003, 0xa0ff0001, 0x03000042, 0x800f0001,
    0x80e40001, 0xa0e40801, 0x03000042, 0x800f0000, 0x80e40000, 0xa0e40801,
    0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0003,
    0x80e40003, 0xa0e40801, 0x02000001, 0x80020001, 0x80000000, 0x02000001,
    0x80040001, 0x80000002, 0x03000005, 0x80070000, 0x80000003, 0x80e40001,
    0x02000001, 0x80080000, 0x80000003, 0x03000005, 0x800f0000, 0x80e40000,
    0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn lookup3 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D baseImage;
//   sampler2D lookupTable;
//   float4 offset;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   offset       c0       1
//   baseImage    s0       1
//   lookupTable  s1       1
//

    ps_2_0
    def c1, 0.125, 0.375, 0.625, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    texld r0, t0, s0
    mov r1.y, c1.x
    rcp r1.z, r0.w
    mad r2.xyz, r0, r1.z, -c0
    mov r1.x, r2.x
    mov r3.y, c1.y
    mov r3.x, r2.y
    mov r2.x, r2.z
    mov r2.y, c1.z
    texld r1, r1, s1
    texld r3, r3, s1
    texld r2, r2, s1
    mov r1.y, r3.x
    mov r1.z, r2.x
    mul r0.xyz, r0.w, r1
    mul r0, r0, v0
    mov oC0, r0

// approximately 17 instruction slots used (4 texture, 13 arithmetic)
#endif

const DWORD lookup3[] =
{
    0xffff0200, 0x0035fffe, 0x42415443, 0x0000001c, 0x0000009f, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x00000098, 0x00000058, 0x00000003,
    0x00020001, 0x00000064, 0x00000000, 0x00000074, 0x00010003, 0x00060001,
    0x00000064, 0x00000000, 0x00000080, 0x00000002, 0x00020001, 0x00000088,
    0x00000000, 0x65736162, 0x67616d49, 0xabab0065, 0x000c0004, 0x00010001,
    0x00000001, 0x00000000, 0x6b6f6f6c, 0x61547075, 0x00656c62, 0x7366666f,
    0xab007465, 0x00030001, 0x00040001, 0x00000001, 0x00000000, 0x325f7370,
    0x4d00305f, 0x6f726369, 0x74666f73, 0x29522820, 0x534c4820, 0x6853204c,
    0x72656461, 0x6d6f4320, 0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934,
    0x00313131, 0x05000051, 0xa00f0001, 0x3e000000, 0x3ec00000, 0x3f200000,
    0x00000000, 0x0200001f, 0x80000000, 0xb0030000, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x03000042, 0x800f0000, 0xb0e40000, 0xa0e40800, 0x02000001,
    0x80020001, 0xa0000001, 0x02000006, 0x80040001, 0x80ff0000, 0x04000004,
    0x80070002, 0x80e40000, 0x80aa0001, 0xa1e40000, 0x02000001, 0x80010001,
    0x80000002, 0x02000001, 0x80020003, 0xa0550001, 0x02000001, 0x80010003,
    0x80550002, 0x02000001, 0x80010002, 0x80aa0002, 0x02000001, 0x80020002,
    0xa0aa0001, 0x03000042, 0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042,
    0x800f0003, 0x80e40003, 0xa0e40801, 0x03000042, 0x800f0002, 0x80e40002,
    0xa0e40801, 0x02000001, 0x80020001, 0x80000003, 0x02000001, 0x80040001,
    0x80000002, 0x03000005, 0x80070000, 0x80ff0000, 0x80e40001, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
const DWORD *lookupShaders[] =
{
    lookup0,
    lookup1,
    lookup2,
    lookup3,
};

#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn grad0 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   float4 color1;
//   float4 color2;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   params       c0       1
//   color1       c1       1
//   color2       c2       1
//

    ps_2_0
    def c3, 1, -0.25, 0, 0
    dcl t0.xy
    dcl v0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.x, c0, r0
    add r0.x, r0.x, c3.y
    add_sat r0.x, r0.x, r0.x
    mov r1, c1
    add r1, -r1, c2
    mad r0, r0.x, r1, c1
    mul r0, r0, v0
    mov oC0, r0

// approximately 10 instruction slots used
#endif

const DWORD grad0[] =
{
    0xffff0200, 0x0033fffe, 0x42415443, 0x0000001c, 0x00000097, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x00000090, 0x00000058, 0x00010002,
    0x00060001, 0x00000060, 0x00000000, 0x00000070, 0x00020002, 0x000a0001,
    0x00000060, 0x00000000, 0x00000077, 0x00000002, 0x00020001, 0x00000080,
    0x00000000, 0x6f6c6f63, 0xab003172, 0x00030001, 0x00040001, 0x00000001,
    0x00000000, 0x6f6c6f63, 0x70003272, 0x6d617261, 0xabab0073, 0x00030001,
    0x00030001, 0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369,
    0x74666f73, 0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320,
    0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051,
    0xa00f0003, 0x3f800000, 0xbe800000, 0x00000000, 0x00000000, 0x0200001f,
    0x80000000, 0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x02000001,
    0x80030000, 0xb0e40000, 0x02000001, 0x80040000, 0xa0000003, 0x03000008,
    0x80010000, 0xa0e40000, 0x80e40000, 0x03000002, 0x80010000, 0x80000000,
    0xa0550003, 0x03000002, 0x80110000, 0x80000000, 0x80000000, 0x02000001,
    0x800f0001, 0xa0e40001, 0x03000002, 0x800f0001, 0x81e40001, 0xa0e40002,
    0x04000004, 0x800f0000, 0x80000000, 0x80e40001, 0xa0e40001, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn grad1 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   float4 color1;
//   float4 color2;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   params       c0       1
//   color1       c1       1
//   color2       c2       1
//

    ps_2_0
    def c3, 1, -0.25, -0.5, 2
    dcl t0.xy
    dcl v0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.x, c0, r0
    add r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    mov r1, c1
    add r1, -r1, c2
    mad r0, r0.x, r1, c1
    mul r0, r0, v0
    mov oC0, r0

// approximately 13 instruction slots used
#endif

const DWORD grad1[] =
{
    0xffff0200, 0x0033fffe, 0x42415443, 0x0000001c, 0x00000097, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x00000090, 0x00000058, 0x00010002,
    0x00060001, 0x00000060, 0x00000000, 0x00000070, 0x00020002, 0x000a0001,
    0x00000060, 0x00000000, 0x00000077, 0x00000002, 0x00020001, 0x00000080,
    0x00000000, 0x6f6c6f63, 0xab003172, 0x00030001, 0x00040001, 0x00000001,
    0x00000000, 0x6f6c6f63, 0x70003272, 0x6d617261, 0xabab0073, 0x00030001,
    0x00030001, 0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369,
    0x74666f73, 0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320,
    0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051,
    0xa00f0003, 0x3f800000, 0xbe800000, 0xbf000000, 0x40000000, 0x0200001f,
    0x80000000, 0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x02000001,
    0x80030000, 0xb0e40000, 0x02000001, 0x80040000, 0xa0000003, 0x03000008,
    0x80010000, 0xa0e40000, 0x80e40000, 0x03000002, 0x80010000, 0x80000000,
    0xa0550003, 0x02000013, 0x80010000, 0x80000000, 0x03000002, 0x80010000,
    0x80000000, 0xa0aa0003, 0x02000023, 0x80010000, 0x80000000, 0x04000004,
    0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003, 0x02000001, 0x800f0001,
    0xa0e40001, 0x03000002, 0x800f0001, 0x81e40001, 0xa0e40002, 0x04000004,
    0x800f0000, 0x80000000, 0x80e40001, 0xa0e40001, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn grad2 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   float4 color1;
//   float4 color2;
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   params       c0       1
//   color1       c1       1
//   color2       c2       1
//   mask         s0       1
//

    ps_2_0
    def c3, 1, -0.25, 0, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    texld r0, t0, s0
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.x, c0, r0
    add r0.x, r0.x, c3.y
    add_sat r0.x, r0.x, r0.x
    mov r1, c1
    add r1, -r1, c2
    mad r1, r0.x, r1, c1
    mul r0, r0.w, r1
    mul r0, r0, v0
    mov oC0, r0

// approximately 12 instruction slots used (1 texture, 11 arithmetic)
#endif

const DWORD grad2[] =
{
    0xffff0200, 0x003dfffe, 0x42415443, 0x0000001c, 0x000000bf, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000b8, 0x0000006c, 0x00010002,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00020002, 0x000a0001,
    0x00000074, 0x00000000, 0x0000008b, 0x00000003, 0x00020001, 0x00000090,
    0x00000000, 0x000000a0, 0x00000002, 0x00020001, 0x000000a8, 0x00000000,
    0x6f6c6f63, 0xab003172, 0x00030001, 0x00040001, 0x00000001, 0x00000000,
    0x6f6c6f63, 0x6d003272, 0x006b7361, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001, 0x00000001,
    0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73, 0x29522820,
    0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970, 0x2e392072,
    0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003, 0x3f800000,
    0xbe800000, 0x00000000, 0x00000000, 0x0200001f, 0x80000000, 0xb0030000,
    0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000, 0x900f0000,
    0x0200001f, 0x90000000, 0xa00f0800, 0x03000042, 0x800f0000, 0xb0e40000,
    0xa0e40800, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40000, 0x80e40000, 0x03000002,
    0x80010000, 0x80000000, 0xa0550003, 0x03000002, 0x80110000, 0x80000000,
    0x80000000, 0x02000001, 0x800f0001, 0xa0e40001, 0x03000002, 0x800f0001,
    0x81e40001, 0xa0e40002, 0x04000004, 0x800f0001, 0x80000000, 0x80e40001,
    0xa0e40001, 0x03000005, 0x800f0000, 0x80ff0000, 0x80e40001, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn grad3 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   float4 color1;
//   float4 color2;
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   params       c0       1
//   color1       c1       1
//   color2       c2       1
//   mask         s0       1
//

    ps_2_0
    def c3, 1, -0.25, -0.5, 2
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    texld r0, t0, s0
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.x, c0, r0
    add r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    mov r1, c1
    add r1, -r1, c2
    mad r1, r0.x, r1, c1
    mul r0, r0.w, r1
    mul r0, r0, v0
    mov oC0, r0

// approximately 15 instruction slots used (1 texture, 14 arithmetic)
#endif

const DWORD grad3[] =
{
    0xffff0200, 0x003dfffe, 0x42415443, 0x0000001c, 0x000000bf, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000b8, 0x0000006c, 0x00010002,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00020002, 0x000a0001,
    0x00000074, 0x00000000, 0x0000008b, 0x00000003, 0x00020001, 0x00000090,
    0x00000000, 0x000000a0, 0x00000002, 0x00020001, 0x000000a8, 0x00000000,
    0x6f6c6f63, 0xab003172, 0x00030001, 0x00040001, 0x00000001, 0x00000000,
    0x6f6c6f63, 0x6d003272, 0x006b7361, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001, 0x00000001,
    0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73, 0x29522820,
    0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970, 0x2e392072,
    0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003, 0x3f800000,
    0xbe800000, 0xbf000000, 0x40000000, 0x0200001f, 0x80000000, 0xb0030000,
    0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000, 0x900f0000,
    0x0200001f, 0x90000000, 0xa00f0800, 0x03000042, 0x800f0000, 0xb0e40000,
    0xa0e40800, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40000, 0x80e40000, 0x03000002,
    0x80010000, 0x80000000, 0xa0550003, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0003, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003,
    0x02000001, 0x800f0001, 0xa0e40001, 0x03000002, 0x800f0001, 0x81e40001,
    0xa0e40002, 0x04000004, 0x800f0001, 0x80000000, 0x80e40001, 0xa0e40001,
    0x03000005, 0x800f0000, 0x80ff0000, 0x80e40001, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
const DWORD *gradShaders[] =
{
    grad0,
    grad1,
    grad2,
    grad3,
};

#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear0 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0, 0.5, -1
    def c4, 1, 0.5, 0.0625, 0.03125
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.z, c3.x
    mov r0.xy, t0
    dp3 r0.x, c16, r0
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    frc r0.z, r0.y
    add r0.y, r0.y, -r0.z
    add r0.w, r0.y, c3.x
    mad r1.x, r0.w, c4.z, c4.w
    add r0.w, r0.x, c3.w
    mad r2.x, r0.y, c4.z, c4.w
    mov r2.y, c3.z
    mov r1.y, c3.z
    mov r3.xy, c4
    mov r4.xy, c3.yzxw
    texld r2, r2, s0
    texld r1, r1, s0
    texld r3, r3, s0
    texld r4, r4, s0
    lrp r5, r0.z, r1, r2
    cmp r1, r0.w, r3, r5
    cmp r0, -r0.x, r4, r1
    mul r0, r0, v0
    mov oC0, r0

// approximately 30 instruction slots used (4 texture, 26 arithmetic)
#endif

const DWORD linear0[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020003,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000004, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0004,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80040000, 0xa0000003, 0x02000001, 0x80030000,
    0xb0e40000, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000002,
    0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x02000013, 0x80040000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81aa0000, 0x03000002, 0x80080000, 0x80550000, 0xa0000003,
    0x04000004, 0x80010001, 0x80ff0000, 0xa0aa0004, 0xa0ff0004, 0x03000002,
    0x80080000, 0x80000000, 0xa0ff0003, 0x04000004, 0x80010002, 0x80550000,
    0xa0aa0004, 0xa0ff0004, 0x02000001, 0x80020002, 0xa0aa0003, 0x02000001,
    0x80020001, 0xa0aa0003, 0x02000001, 0x80030003, 0xa0e40004, 0x02000001,
    0x80030004, 0xa0c90003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0003,
    0x80e40003, 0xa0e40800, 0x03000042, 0x800f0004, 0x80e40004, 0xa0e40800,
    0x04000012, 0x800f0005, 0x80aa0000, 0x80e40001, 0x80e40002, 0x04000058,
    0x800f0001, 0x80ff0000, 0x80e40003, 0x80e40005, 0x04000058, 0x800f0000,
    0x81000000, 0x80e40004, 0x80e40001, 0x03000005, 0x800f0000, 0x80e40000,
    0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear1 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0.5, -0.5, 2
    def c4, 0.0625, 0.03125, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.x, c16, r0
    mul r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c4.x, c4.y
    mad r2.x, r0.z, c4.x, c4.y
    mov r2.y, c3.y
    mov r1.y, c3.y
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    mul r0, r3, v0
    mov oC0, r0

// approximately 28 instruction slots used (2 texture, 26 arithmetic)
#endif

const DWORD linear1[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020003,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000004, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0004,
    0x3d800000, 0x3d000000, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000005,
    0x80010000, 0x80000000, 0xa0550003, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0003, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000002, 0x80010000, 0x80000000, 0xa1000002, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550002, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000003, 0x04000004, 0x80010001, 0x80000000, 0xa0000004, 0xa0550004,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000004, 0xa0550004, 0x02000001,
    0x80020002, 0xa0550003, 0x02000001, 0x80020001, 0xa0550003, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40800, 0x04000012, 0x800f0003, 0x80550000, 0x80e40002, 0x80e40001,
    0x03000005, 0x800f0000, 0x80e40003, 0x90e40000, 0x02000001, 0x800f0800,
    0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear2 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0.0625, 0.03125, 0.5
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.x, c16, r0
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c3.y, c3.z
    mad r2.x, r0.z, c3.y, c3.z
    mov r2.y, c3.w
    mov r1.y, c3.w
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    mul r0, r3, v0
    mov oC0, r0

// approximately 24 instruction slots used (2 texture, 22 arithmetic)
#endif

const DWORD linear2[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020003,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000004, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000002, 0x80010000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550002,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000003, 0x04000004, 0x80010001, 0x80000000,
    0xa0550003, 0xa0aa0003, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550003,
    0xa0aa0003, 0x02000001, 0x80020002, 0xa0ff0003, 0x02000001, 0x80020001,
    0xa0ff0003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x04000012, 0x800f0003, 0x80550000,
    0x80e40002, 0x80e40001, 0x03000005, 0x800f0000, 0x80e40003, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear4 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0, 0.5, -1
    def c8, 1, 0.5, 0.0625, 0.03125
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.z, c7.x
    mov r0.xy, t0
    dp3 r0.x, c16, r0
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c6.x
    mul_sat r0.z, r0.z, c6.y
    add r0.y, r0.y, r0.z
    frc r0.z, r0.y
    add r0.y, r0.y, -r0.z
    add r0.w, r0.y, c7.x
    mad r1.x, r0.w, c8.z, c8.w
    add r0.w, r0.x, c7.w
    mad r2.x, r0.y, c8.z, c8.w
    mov r2.y, c7.z
    mov r1.y, c7.z
    mov r3.xy, c8
    mov r4.xy, c7.yzxw
    texld r2, r2, s0
    texld r1, r1, s0
    texld r3, r3, s0
    texld r4, r4, s0
    lrp r5, r0.z, r1, r2
    cmp r1, r0.w, r3, r5
    cmp r0, -r0.x, r4, r1
    mul r0, r0, v0
    mov oC0, r0

// approximately 42 instruction slots used (4 texture, 38 arithmetic)
#endif

const DWORD linear4[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020007,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000008, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0008,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80040000, 0xa0000007, 0x02000001, 0x80030000,
    0xb0e40000, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000002,
    0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000006, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550006, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x02000013, 0x80040000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81aa0000, 0x03000002, 0x80080000, 0x80550000, 0xa0000007,
    0x04000004, 0x80010001, 0x80ff0000, 0xa0aa0008, 0xa0ff0008, 0x03000002,
    0x80080000, 0x80000000, 0xa0ff0007, 0x04000004, 0x80010002, 0x80550000,
    0xa0aa0008, 0xa0ff0008, 0x02000001, 0x80020002, 0xa0aa0007, 0x02000001,
    0x80020001, 0xa0aa0007, 0x02000001, 0x80030003, 0xa0e40008, 0x02000001,
    0x80030004, 0xa0c90007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0003,
    0x80e40003, 0xa0e40800, 0x03000042, 0x800f0004, 0x80e40004, 0xa0e40800,
    0x04000012, 0x800f0005, 0x80aa0000, 0x80e40001, 0x80e40002, 0x04000058,
    0x800f0001, 0x80ff0000, 0x80e40003, 0x80e40005, 0x04000058, 0x800f0000,
    0x81000000, 0x80e40004, 0x80e40001, 0x03000005, 0x800f0000, 0x80e40000,
    0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear5 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0.5, -0.5, 2
    def c8, 0.0625, 0.03125, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c7.x
    dp3 r0.x, c16, r0
    mul r0.x, r0.x, c7.y
    frc r0.x, r0.x
    add r0.x, r0.x, c7.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c7.w, c7.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c8.x, c8.y
    mad r2.x, r0.z, c8.x, c8.y
    mov r2.y, c7.y
    mov r1.y, c7.y
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    mul r0, r3, v0
    mov oC0, r0

// approximately 40 instruction slots used (2 texture, 38 arithmetic)
#endif

const DWORD linear5[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020007,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000008, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0008,
    0x3d800000, 0x3d000000, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000005,
    0x80010000, 0x80000000, 0xa0550007, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0007, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0007, 0xa0000007,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005,
    0x03000002, 0x80010000, 0x80000000, 0xa1000006, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550006, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000007, 0x04000004, 0x80010001, 0x80000000, 0xa0000008, 0xa0550008,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000008, 0xa0550008, 0x02000001,
    0x80020002, 0xa0550007, 0x02000001, 0x80020001, 0xa0550007, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40800, 0x04000012, 0x800f0003, 0x80550000, 0x80e40002, 0x80e40001,
    0x03000005, 0x800f0000, 0x80e40003, 0x90e40000, 0x02000001, 0x800f0800,
    0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear6 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0.0625, 0.03125, 0.5
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c7.x
    dp3 r0.x, c16, r0
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c7.y, c7.z
    mad r2.x, r0.z, c7.y, c7.z
    mov r2.y, c7.w
    mov r1.y, c7.w
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    mul r0, r3, v0
    mov oC0, r0

// approximately 36 instruction slots used (2 texture, 34 arithmetic)
#endif

const DWORD linear6[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020007,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000008, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550001,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000002, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550002,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000003, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000004, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550004,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000005, 0x03000002, 0x80010000, 0x80000000, 0xa1000006,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550006,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000007, 0x04000004, 0x80010001, 0x80000000,
    0xa0550007, 0xa0aa0007, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550007,
    0xa0aa0007, 0x02000001, 0x80020002, 0xa0ff0007, 0x02000001, 0x80020001,
    0xa0ff0007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x04000012, 0x800f0003, 0x80550000,
    0x80e40002, 0x80e40001, 0x03000005, 0x800f0000, 0x80e40003, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear8 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0, 0.5, -1
    def c4, 1, 0.5, 0.0625, 0.03125
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.z, c3.x
    mov r0.xy, t1
    dp3 r0.x, c16, r0
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    frc r0.z, r0.y
    add r0.y, r0.y, -r0.z
    add r0.w, r0.y, c3.x
    mad r1.x, r0.w, c4.z, c4.w
    add r0.w, r0.x, c3.w
    mad r2.x, r0.y, c4.z, c4.w
    mov r2.y, c3.z
    mov r1.y, c3.z
    mov r3.xy, c4
    mov r4.xy, c3.yzxw
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, r3, s1
    texld r4, r4, s1
    texld r5, t0, s0
    lrp r6, r0.z, r1, r2
    cmp r1, r0.w, r3, r6
    cmp r0, -r0.x, r4, r1
    mul r0, r5.w, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 32 instruction slots used (5 texture, 27 arithmetic)
#endif

const DWORD linear8[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020003,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0004,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80040000, 0xa0000003, 0x02000001, 0x80030000,
    0xb0e40001, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000002,
    0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x02000013, 0x80040000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81aa0000, 0x03000002, 0x80080000, 0x80550000, 0xa0000003,
    0x04000004, 0x80010001, 0x80ff0000, 0xa0aa0004, 0xa0ff0004, 0x03000002,
    0x80080000, 0x80000000, 0xa0ff0003, 0x04000004, 0x80010002, 0x80550000,
    0xa0aa0004, 0xa0ff0004, 0x02000001, 0x80020002, 0xa0aa0003, 0x02000001,
    0x80020001, 0xa0aa0003, 0x02000001, 0x80030003, 0xa0e40004, 0x02000001,
    0x80030004, 0xa0c90003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003,
    0x80e40003, 0xa0e40801, 0x03000042, 0x800f0004, 0x80e40004, 0xa0e40801,
    0x03000042, 0x800f0005, 0xb0e40000, 0xa0e40800, 0x04000012, 0x800f0006,
    0x80aa0000, 0x80e40001, 0x80e40002, 0x04000058, 0x800f0001, 0x80ff0000,
    0x80e40003, 0x80e40006, 0x04000058, 0x800f0000, 0x81000000, 0x80e40004,
    0x80e40001, 0x03000005, 0x800f0000, 0x80ff0005, 0x80e40000, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear9 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0.5, -0.5, 2
    def c4, 0.0625, 0.03125, 0, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.x, c16, r0
    mul r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c4.x, c4.y
    mad r2.x, r0.z, c4.x, c4.y
    mov r2.y, c3.y
    mov r1.y, c3.y
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 30 instruction slots used (3 texture, 27 arithmetic)
#endif

const DWORD linear9[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020003,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0004,
    0x3d800000, 0x3d000000, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000005,
    0x80010000, 0x80000000, 0xa0550003, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0003, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000002, 0x80010000, 0x80000000, 0xa1000002, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550002, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000003, 0x04000004, 0x80010001, 0x80000000, 0xa0000004, 0xa0550004,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000004, 0xa0550004, 0x02000001,
    0x80020002, 0xa0550003, 0x02000001, 0x80020001, 0xa0550003, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0004, 0x80550000, 0x80e40002, 0x80e40001, 0x03000005, 0x800f0000,
    0x80ff0003, 0x80e40004, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear10 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0.0625, 0.03125, 0.5
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.x, c16, r0
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c3.y, c3.z
    mad r2.x, r0.z, c3.y, c3.z
    mov r2.y, c3.w
    mov r1.y, c3.w
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 26 instruction slots used (3 texture, 23 arithmetic)
#endif

const DWORD linear10[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020003,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000002, 0x80010000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550002,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000003, 0x04000004, 0x80010001, 0x80000000,
    0xa0550003, 0xa0aa0003, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550003,
    0xa0aa0003, 0x02000001, 0x80020002, 0xa0ff0003, 0x02000001, 0x80020001,
    0xa0ff0003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000,
    0xa0e40800, 0x04000012, 0x800f0004, 0x80550000, 0x80e40002, 0x80e40001,
    0x03000005, 0x800f0000, 0x80ff0003, 0x80e40004, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear12 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0, 0.5, -1
    def c8, 1, 0.5, 0.0625, 0.03125
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.z, c7.x
    mov r0.xy, t1
    dp3 r0.x, c16, r0
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c6.x
    mul_sat r0.z, r0.z, c6.y
    add r0.y, r0.y, r0.z
    frc r0.z, r0.y
    add r0.y, r0.y, -r0.z
    add r0.w, r0.y, c7.x
    mad r1.x, r0.w, c8.z, c8.w
    add r0.w, r0.x, c7.w
    mad r2.x, r0.y, c8.z, c8.w
    mov r2.y, c7.z
    mov r1.y, c7.z
    mov r3.xy, c8
    mov r4.xy, c7.yzxw
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, r3, s1
    texld r4, r4, s1
    texld r5, t0, s0
    lrp r6, r0.z, r1, r2
    cmp r1, r0.w, r3, r6
    cmp r0, -r0.x, r4, r1
    mul r0, r5.w, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 44 instruction slots used (5 texture, 39 arithmetic)
#endif

const DWORD linear12[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020007,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0008,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80040000, 0xa0000007, 0x02000001, 0x80030000,
    0xb0e40001, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000002,
    0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000006, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550006, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x02000013, 0x80040000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81aa0000, 0x03000002, 0x80080000, 0x80550000, 0xa0000007,
    0x04000004, 0x80010001, 0x80ff0000, 0xa0aa0008, 0xa0ff0008, 0x03000002,
    0x80080000, 0x80000000, 0xa0ff0007, 0x04000004, 0x80010002, 0x80550000,
    0xa0aa0008, 0xa0ff0008, 0x02000001, 0x80020002, 0xa0aa0007, 0x02000001,
    0x80020001, 0xa0aa0007, 0x02000001, 0x80030003, 0xa0e40008, 0x02000001,
    0x80030004, 0xa0c90007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003,
    0x80e40003, 0xa0e40801, 0x03000042, 0x800f0004, 0x80e40004, 0xa0e40801,
    0x03000042, 0x800f0005, 0xb0e40000, 0xa0e40800, 0x04000012, 0x800f0006,
    0x80aa0000, 0x80e40001, 0x80e40002, 0x04000058, 0x800f0001, 0x80ff0000,
    0x80e40003, 0x80e40006, 0x04000058, 0x800f0000, 0x81000000, 0x80e40004,
    0x80e40001, 0x03000005, 0x800f0000, 0x80ff0005, 0x80e40000, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear13 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0.5, -0.5, 2
    def c8, 0.0625, 0.03125, 0, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c7.x
    dp3 r0.x, c16, r0
    mul r0.x, r0.x, c7.y
    frc r0.x, r0.x
    add r0.x, r0.x, c7.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c7.w, c7.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c8.x, c8.y
    mad r2.x, r0.z, c8.x, c8.y
    mov r2.y, c7.y
    mov r1.y, c7.y
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 42 instruction slots used (3 texture, 39 arithmetic)
#endif

const DWORD linear13[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020007,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0008,
    0x3d800000, 0x3d000000, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000005,
    0x80010000, 0x80000000, 0xa0550007, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0007, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0007, 0xa0000007,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005,
    0x03000002, 0x80010000, 0x80000000, 0xa1000006, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550006, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000007, 0x04000004, 0x80010001, 0x80000000, 0xa0000008, 0xa0550008,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000008, 0xa0550008, 0x02000001,
    0x80020002, 0xa0550007, 0x02000001, 0x80020001, 0xa0550007, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0004, 0x80550000, 0x80e40002, 0x80e40001, 0x03000005, 0x800f0000,
    0x80ff0003, 0x80e40004, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear14 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0.0625, 0.03125, 0.5
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c7.x
    dp3 r0.x, c16, r0
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c7.y, c7.z
    mad r2.x, r0.z, c7.y, c7.z
    mov r2.y, c7.w
    mov r1.y, c7.w
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 38 instruction slots used (3 texture, 35 arithmetic)
#endif

const DWORD linear14[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020007,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550001,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000002, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550002,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000003, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000004, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550004,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000005, 0x03000002, 0x80010000, 0x80000000, 0xa1000006,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550006,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000007, 0x04000004, 0x80010001, 0x80000000,
    0xa0550007, 0xa0aa0007, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550007,
    0xa0aa0007, 0x02000001, 0x80020002, 0xa0ff0007, 0x02000001, 0x80020001,
    0xa0ff0007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000,
    0xa0e40800, 0x04000012, 0x800f0004, 0x80550000, 0x80e40002, 0x80e40001,
    0x03000005, 0x800f0000, 0x80ff0003, 0x80e40004, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear16 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0, 0.5, -1
    def c4, 1, 0.5, 0.0625, 0.03125
    def c5, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.z, c3.x
    mov r0.xy, t0
    dp3 r0.x, c16, r0
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    frc r0.z, r0.y
    add r0.y, r0.y, -r0.z
    add r0.w, r0.y, c3.x
    mad r1.x, r0.w, c4.z, c4.w
    add r0.w, r0.x, c3.w
    mad r2.x, r0.y, c4.z, c4.w
    mov r2.y, c3.z
    mov r1.y, c3.z
    mov r3.xy, c4
    mov r4.xy, c3.yzxw
    texld r2, r2, s0
    texld r1, r1, s0
    texld r3, r3, s0
    texld r4, r4, s0
    lrp r5, r0.z, r1, r2
    cmp r1, r0.w, r3, r5
    cmp r0, -r0.x, r4, r1
    log r1.x, r0.x
    log r1.y, r0.y
    log r1.z, r0.z
    mul r1.xyz, r1, c5.x
    exp r2.x, r1.x
    exp r2.y, r1.y
    exp r2.z, r1.z
    mad r0.xyz, r2, c5.y, c5.z
    mul r0, r0, v0
    mov oC0, r0

// approximately 38 instruction slots used (4 texture, 34 arithmetic)
#endif

const DWORD linear16[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020003,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000004, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0004,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x05000051, 0xa00f0005,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80040000, 0xa0000003, 0x02000001, 0x80030000,
    0xb0e40000, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000002,
    0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x02000013, 0x80040000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81aa0000, 0x03000002, 0x80080000, 0x80550000, 0xa0000003,
    0x04000004, 0x80010001, 0x80ff0000, 0xa0aa0004, 0xa0ff0004, 0x03000002,
    0x80080000, 0x80000000, 0xa0ff0003, 0x04000004, 0x80010002, 0x80550000,
    0xa0aa0004, 0xa0ff0004, 0x02000001, 0x80020002, 0xa0aa0003, 0x02000001,
    0x80020001, 0xa0aa0003, 0x02000001, 0x80030003, 0xa0e40004, 0x02000001,
    0x80030004, 0xa0c90003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0003,
    0x80e40003, 0xa0e40800, 0x03000042, 0x800f0004, 0x80e40004, 0xa0e40800,
    0x04000012, 0x800f0005, 0x80aa0000, 0x80e40001, 0x80e40002, 0x04000058,
    0x800f0001, 0x80ff0000, 0x80e40003, 0x80e40005, 0x04000058, 0x800f0000,
    0x81000000, 0x80e40004, 0x80e40001, 0x0200000f, 0x80010001, 0x80000000,
    0x0200000f, 0x80020001, 0x80550000, 0x0200000f, 0x80040001, 0x80aa0000,
    0x03000005, 0x80070001, 0x80e40001, 0xa0000005, 0x0200000e, 0x80010002,
    0x80000001, 0x0200000e, 0x80020002, 0x80550001, 0x0200000e, 0x80040002,
    0x80aa0001, 0x04000004, 0x80070000, 0x80e40002, 0xa0550005, 0xa0aa0005,
    0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800,
    0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear17 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0.5, -0.5, 2
    def c4, 0.0625, 0.03125, 0.416667014, 0
    def c5, 1.05499995, -0.0549999997, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.x, c16, r0
    mul r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c4.x, c4.y
    mad r2.x, r0.z, c4.x, c4.y
    mov r2.y, c3.y
    mov r1.y, c3.y
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    log r0.x, r3.x
    log r0.y, r3.y
    log r0.z, r3.z
    mul r0.xyz, r0, c4.z
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r3.xyz, r1, c5.x, c5.y
    mul r0, r3, v0
    mov oC0, r0

// approximately 36 instruction slots used (2 texture, 34 arithmetic)
#endif

const DWORD linear17[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020003,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000004, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0004,
    0x3d800000, 0x3d000000, 0x3ed55561, 0x00000000, 0x05000051, 0xa00f0005,
    0x3f870a3d, 0xbd6147ae, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000005,
    0x80010000, 0x80000000, 0xa0550003, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0003, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000002, 0x80010000, 0x80000000, 0xa1000002, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550002, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000003, 0x04000004, 0x80010001, 0x80000000, 0xa0000004, 0xa0550004,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000004, 0xa0550004, 0x02000001,
    0x80020002, 0xa0550003, 0x02000001, 0x80020001, 0xa0550003, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40800, 0x04000012, 0x800f0003, 0x80550000, 0x80e40002, 0x80e40001,
    0x0200000f, 0x80010000, 0x80000003, 0x0200000f, 0x80020000, 0x80550003,
    0x0200000f, 0x80040000, 0x80aa0003, 0x03000005, 0x80070000, 0x80e40000,
    0xa0aa0004, 0x0200000e, 0x80010001, 0x80000000, 0x0200000e, 0x80020001,
    0x80550000, 0x0200000e, 0x80040001, 0x80aa0000, 0x04000004, 0x80070003,
    0x80e40001, 0xa0000005, 0xa0550005, 0x03000005, 0x800f0000, 0x80e40003,
    0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear18 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0.0625, 0.03125, 0.5
    def c4, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.x, c16, r0
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c3.y, c3.z
    mad r2.x, r0.z, c3.y, c3.z
    mov r2.y, c3.w
    mov r1.y, c3.w
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    log r0.x, r3.x
    log r0.y, r3.y
    log r0.z, r3.z
    mul r0.xyz, r0, c4.x
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r3.xyz, r1, c4.y, c4.z
    mul r0, r3, v0
    mov oC0, r0

// approximately 32 instruction slots used (2 texture, 30 arithmetic)
#endif

const DWORD linear18[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020003,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000004, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x05000051, 0xa00f0004,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000002, 0x80010000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550002,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000003, 0x04000004, 0x80010001, 0x80000000,
    0xa0550003, 0xa0aa0003, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550003,
    0xa0aa0003, 0x02000001, 0x80020002, 0xa0ff0003, 0x02000001, 0x80020001,
    0xa0ff0003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x04000012, 0x800f0003, 0x80550000,
    0x80e40002, 0x80e40001, 0x0200000f, 0x80010000, 0x80000003, 0x0200000f,
    0x80020000, 0x80550003, 0x0200000f, 0x80040000, 0x80aa0003, 0x03000005,
    0x80070000, 0x80e40000, 0xa0000004, 0x0200000e, 0x80010001, 0x80000000,
    0x0200000e, 0x80020001, 0x80550000, 0x0200000e, 0x80040001, 0x80aa0000,
    0x04000004, 0x80070003, 0x80e40001, 0xa0550004, 0xa0aa0004, 0x03000005,
    0x800f0000, 0x80e40003, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear20 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0, 0.5, -1
    def c8, 1, 0.5, 0.0625, 0.03125
    def c9, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.z, c7.x
    mov r0.xy, t0
    dp3 r0.x, c16, r0
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c6.x
    mul_sat r0.z, r0.z, c6.y
    add r0.y, r0.y, r0.z
    frc r0.z, r0.y
    add r0.y, r0.y, -r0.z
    add r0.w, r0.y, c7.x
    mad r1.x, r0.w, c8.z, c8.w
    add r0.w, r0.x, c7.w
    mad r2.x, r0.y, c8.z, c8.w
    mov r2.y, c7.z
    mov r1.y, c7.z
    mov r3.xy, c8
    mov r4.xy, c7.yzxw
    texld r2, r2, s0
    texld r1, r1, s0
    texld r3, r3, s0
    texld r4, r4, s0
    lrp r5, r0.z, r1, r2
    cmp r1, r0.w, r3, r5
    cmp r0, -r0.x, r4, r1
    log r1.x, r0.x
    log r1.y, r0.y
    log r1.z, r0.z
    mul r1.xyz, r1, c9.x
    exp r2.x, r1.x
    exp r2.y, r1.y
    exp r2.z, r1.z
    mad r0.xyz, r2, c9.y, c9.z
    mul r0, r0, v0
    mov oC0, r0

// approximately 50 instruction slots used (4 texture, 46 arithmetic)
#endif

const DWORD linear20[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020007,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000008, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0008,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x05000051, 0xa00f0009,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80040000, 0xa0000007, 0x02000001, 0x80030000,
    0xb0e40000, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000002,
    0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000006, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550006, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x02000013, 0x80040000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81aa0000, 0x03000002, 0x80080000, 0x80550000, 0xa0000007,
    0x04000004, 0x80010001, 0x80ff0000, 0xa0aa0008, 0xa0ff0008, 0x03000002,
    0x80080000, 0x80000000, 0xa0ff0007, 0x04000004, 0x80010002, 0x80550000,
    0xa0aa0008, 0xa0ff0008, 0x02000001, 0x80020002, 0xa0aa0007, 0x02000001,
    0x80020001, 0xa0aa0007, 0x02000001, 0x80030003, 0xa0e40008, 0x02000001,
    0x80030004, 0xa0c90007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0003,
    0x80e40003, 0xa0e40800, 0x03000042, 0x800f0004, 0x80e40004, 0xa0e40800,
    0x04000012, 0x800f0005, 0x80aa0000, 0x80e40001, 0x80e40002, 0x04000058,
    0x800f0001, 0x80ff0000, 0x80e40003, 0x80e40005, 0x04000058, 0x800f0000,
    0x81000000, 0x80e40004, 0x80e40001, 0x0200000f, 0x80010001, 0x80000000,
    0x0200000f, 0x80020001, 0x80550000, 0x0200000f, 0x80040001, 0x80aa0000,
    0x03000005, 0x80070001, 0x80e40001, 0xa0000009, 0x0200000e, 0x80010002,
    0x80000001, 0x0200000e, 0x80020002, 0x80550001, 0x0200000e, 0x80040002,
    0x80aa0001, 0x04000004, 0x80070000, 0x80e40002, 0xa0550009, 0xa0aa0009,
    0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800,
    0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear21 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0.5, -0.5, 2
    def c8, 0.0625, 0.03125, 0.416667014, 0
    def c9, 1.05499995, -0.0549999997, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c7.x
    dp3 r0.x, c16, r0
    mul r0.x, r0.x, c7.y
    frc r0.x, r0.x
    add r0.x, r0.x, c7.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c7.w, c7.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c8.x, c8.y
    mad r2.x, r0.z, c8.x, c8.y
    mov r2.y, c7.y
    mov r1.y, c7.y
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    log r0.x, r3.x
    log r0.y, r3.y
    log r0.z, r3.z
    mul r0.xyz, r0, c8.z
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r3.xyz, r1, c9.x, c9.y
    mul r0, r3, v0
    mov oC0, r0

// approximately 48 instruction slots used (2 texture, 46 arithmetic)
#endif

const DWORD linear21[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020007,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000008, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0008,
    0x3d800000, 0x3d000000, 0x3ed55561, 0x00000000, 0x05000051, 0xa00f0009,
    0x3f870a3d, 0xbd6147ae, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000005,
    0x80010000, 0x80000000, 0xa0550007, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0007, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0007, 0xa0000007,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005,
    0x03000002, 0x80010000, 0x80000000, 0xa1000006, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550006, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000007, 0x04000004, 0x80010001, 0x80000000, 0xa0000008, 0xa0550008,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000008, 0xa0550008, 0x02000001,
    0x80020002, 0xa0550007, 0x02000001, 0x80020001, 0xa0550007, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40800, 0x04000012, 0x800f0003, 0x80550000, 0x80e40002, 0x80e40001,
    0x0200000f, 0x80010000, 0x80000003, 0x0200000f, 0x80020000, 0x80550003,
    0x0200000f, 0x80040000, 0x80aa0003, 0x03000005, 0x80070000, 0x80e40000,
    0xa0aa0008, 0x0200000e, 0x80010001, 0x80000000, 0x0200000e, 0x80020001,
    0x80550000, 0x0200000e, 0x80040001, 0x80aa0000, 0x04000004, 0x80070003,
    0x80e40001, 0xa0000009, 0xa0550009, 0x03000005, 0x800f0000, 0x80e40003,
    0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear22 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0.0625, 0.03125, 0.5
    def c8, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c7.x
    dp3 r0.x, c16, r0
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c7.y, c7.z
    mad r2.x, r0.z, c7.y, c7.z
    mov r2.y, c7.w
    mov r1.y, c7.w
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    log r0.x, r3.x
    log r0.y, r3.y
    log r0.z, r3.z
    mul r0.xyz, r0, c8.x
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r3.xyz, r1, c8.y, c8.z
    mul r0, r3, v0
    mov oC0, r0

// approximately 44 instruction slots used (2 texture, 42 arithmetic)
#endif

const DWORD linear22[] =
{
    0xffff0200, 0x0038fffe, 0x42415443, 0x0000001c, 0x000000ab, 0xffff0200,
    0x00000003, 0x0000001c, 0x20000100, 0x000000a4, 0x00000058, 0x00000003,
    0x00020001, 0x00000060, 0x00000000, 0x00000070, 0x00000002, 0x00020007,
    0x0000007c, 0x00000000, 0x0000008c, 0x00100002, 0x00420001, 0x00000094,
    0x00000000, 0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001,
    0x00000000, 0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001,
    0x00000008, 0x00000000, 0x61726170, 0xab00736d, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x05000051, 0xa00f0008,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550001,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000002, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550002,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000003, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000004, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550004,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000005, 0x03000002, 0x80010000, 0x80000000, 0xa1000006,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550006,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000007, 0x04000004, 0x80010001, 0x80000000,
    0xa0550007, 0xa0aa0007, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550007,
    0xa0aa0007, 0x02000001, 0x80020002, 0xa0ff0007, 0x02000001, 0x80020001,
    0xa0ff0007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x04000012, 0x800f0003, 0x80550000,
    0x80e40002, 0x80e40001, 0x0200000f, 0x80010000, 0x80000003, 0x0200000f,
    0x80020000, 0x80550003, 0x0200000f, 0x80040000, 0x80aa0003, 0x03000005,
    0x80070000, 0x80e40000, 0xa0000008, 0x0200000e, 0x80010001, 0x80000000,
    0x0200000e, 0x80020001, 0x80550000, 0x0200000e, 0x80040001, 0x80aa0000,
    0x04000004, 0x80070003, 0x80e40001, 0xa0550008, 0xa0aa0008, 0x03000005,
    0x800f0000, 0x80e40003, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear24 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0, 0.5, -1
    def c4, 1, 0.5, 0.0625, 0.03125
    def c5, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.z, c3.x
    mov r0.xy, t1
    dp3 r0.x, c16, r0
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    frc r0.z, r0.y
    add r0.y, r0.y, -r0.z
    add r0.w, r0.y, c3.x
    mad r1.x, r0.w, c4.z, c4.w
    add r0.w, r0.x, c3.w
    mad r2.x, r0.y, c4.z, c4.w
    mov r2.y, c3.z
    mov r1.y, c3.z
    mov r3.xy, c4
    mov r4.xy, c3.yzxw
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, r3, s1
    texld r4, r4, s1
    texld r5, t0, s0
    lrp r6, r0.z, r1, r2
    cmp r1, r0.w, r3, r6
    cmp r0, -r0.x, r4, r1
    log r1.x, r0.x
    log r1.y, r0.y
    log r1.z, r0.z
    mul r1.xyz, r1, c5.x
    exp r2.x, r1.x
    exp r2.y, r1.y
    exp r2.z, r1.z
    mad r0.xyz, r2, c5.y, c5.z
    mul r0, r5.w, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 40 instruction slots used (5 texture, 35 arithmetic)
#endif

const DWORD linear24[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020003,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0004,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x05000051, 0xa00f0005,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80040000, 0xa0000003, 0x02000001, 0x80030000,
    0xb0e40001, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000002,
    0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x02000013, 0x80040000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81aa0000, 0x03000002, 0x80080000, 0x80550000, 0xa0000003,
    0x04000004, 0x80010001, 0x80ff0000, 0xa0aa0004, 0xa0ff0004, 0x03000002,
    0x80080000, 0x80000000, 0xa0ff0003, 0x04000004, 0x80010002, 0x80550000,
    0xa0aa0004, 0xa0ff0004, 0x02000001, 0x80020002, 0xa0aa0003, 0x02000001,
    0x80020001, 0xa0aa0003, 0x02000001, 0x80030003, 0xa0e40004, 0x02000001,
    0x80030004, 0xa0c90003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003,
    0x80e40003, 0xa0e40801, 0x03000042, 0x800f0004, 0x80e40004, 0xa0e40801,
    0x03000042, 0x800f0005, 0xb0e40000, 0xa0e40800, 0x04000012, 0x800f0006,
    0x80aa0000, 0x80e40001, 0x80e40002, 0x04000058, 0x800f0001, 0x80ff0000,
    0x80e40003, 0x80e40006, 0x04000058, 0x800f0000, 0x81000000, 0x80e40004,
    0x80e40001, 0x0200000f, 0x80010001, 0x80000000, 0x0200000f, 0x80020001,
    0x80550000, 0x0200000f, 0x80040001, 0x80aa0000, 0x03000005, 0x80070001,
    0x80e40001, 0xa0000005, 0x0200000e, 0x80010002, 0x80000001, 0x0200000e,
    0x80020002, 0x80550001, 0x0200000e, 0x80040002, 0x80aa0001, 0x04000004,
    0x80070000, 0x80e40002, 0xa0550005, 0xa0aa0005, 0x03000005, 0x800f0000,
    0x80ff0005, 0x80e40000, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear25 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0.5, -0.5, 2
    def c4, 0.0625, 0.03125, 0.416667014, 0
    def c5, 1.05499995, -0.0549999997, 0, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.x, c16, r0
    mul r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c4.x, c4.y
    mad r2.x, r0.z, c4.x, c4.y
    mov r2.y, c3.y
    mov r1.y, c3.y
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    log r0.x, r4.x
    log r0.y, r4.y
    log r0.z, r4.z
    mul r0.xyz, r0, c4.z
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r4.xyz, r1, c5.x, c5.y
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 38 instruction slots used (3 texture, 35 arithmetic)
#endif

const DWORD linear25[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020003,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0004,
    0x3d800000, 0x3d000000, 0x3ed55561, 0x00000000, 0x05000051, 0xa00f0005,
    0x3f870a3d, 0xbd6147ae, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000005,
    0x80010000, 0x80000000, 0xa0550003, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0003, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000002, 0x80010000, 0x80000000, 0xa1000002, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550002, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000003, 0x04000004, 0x80010001, 0x80000000, 0xa0000004, 0xa0550004,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000004, 0xa0550004, 0x02000001,
    0x80020002, 0xa0550003, 0x02000001, 0x80020001, 0xa0550003, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0004, 0x80550000, 0x80e40002, 0x80e40001, 0x0200000f, 0x80010000,
    0x80000004, 0x0200000f, 0x80020000, 0x80550004, 0x0200000f, 0x80040000,
    0x80aa0004, 0x03000005, 0x80070000, 0x80e40000, 0xa0aa0004, 0x0200000e,
    0x80010001, 0x80000000, 0x0200000e, 0x80020001, 0x80550000, 0x0200000e,
    0x80040001, 0x80aa0000, 0x04000004, 0x80070004, 0x80e40001, 0xa0000005,
    0xa0550005, 0x03000005, 0x800f0000, 0x80ff0003, 0x80e40004, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear26 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0.0625, 0.03125, 0.5
    def c4, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.x, c16, r0
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c3.y, c3.z
    mad r2.x, r0.z, c3.y, c3.z
    mov r2.y, c3.w
    mov r1.y, c3.w
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    log r0.x, r4.x
    log r0.y, r4.y
    log r0.z, r4.z
    mul r0.xyz, r0, c4.x
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r4.xyz, r1, c4.y, c4.z
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 34 instruction slots used (3 texture, 31 arithmetic)
#endif

const DWORD linear26[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020003,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x05000051, 0xa00f0004,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000002, 0x80010000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550002,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000003, 0x04000004, 0x80010001, 0x80000000,
    0xa0550003, 0xa0aa0003, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550003,
    0xa0aa0003, 0x02000001, 0x80020002, 0xa0ff0003, 0x02000001, 0x80020001,
    0xa0ff0003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000,
    0xa0e40800, 0x04000012, 0x800f0004, 0x80550000, 0x80e40002, 0x80e40001,
    0x0200000f, 0x80010000, 0x80000004, 0x0200000f, 0x80020000, 0x80550004,
    0x0200000f, 0x80040000, 0x80aa0004, 0x03000005, 0x80070000, 0x80e40000,
    0xa0000004, 0x0200000e, 0x80010001, 0x80000000, 0x0200000e, 0x80020001,
    0x80550000, 0x0200000e, 0x80040001, 0x80aa0000, 0x04000004, 0x80070004,
    0x80e40001, 0xa0550004, 0xa0aa0004, 0x03000005, 0x800f0000, 0x80ff0003,
    0x80e40004, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001,
    0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear28 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0, 0.5, -1
    def c8, 1, 0.5, 0.0625, 0.03125
    def c9, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.z, c7.x
    mov r0.xy, t1
    dp3 r0.x, c16, r0
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c6.x
    mul_sat r0.z, r0.z, c6.y
    add r0.y, r0.y, r0.z
    frc r0.z, r0.y
    add r0.y, r0.y, -r0.z
    add r0.w, r0.y, c7.x
    mad r1.x, r0.w, c8.z, c8.w
    add r0.w, r0.x, c7.w
    mad r2.x, r0.y, c8.z, c8.w
    mov r2.y, c7.z
    mov r1.y, c7.z
    mov r3.xy, c8
    mov r4.xy, c7.yzxw
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, r3, s1
    texld r4, r4, s1
    texld r5, t0, s0
    lrp r6, r0.z, r1, r2
    cmp r1, r0.w, r3, r6
    cmp r0, -r0.x, r4, r1
    log r1.x, r0.x
    log r1.y, r0.y
    log r1.z, r0.z
    mul r1.xyz, r1, c9.x
    exp r2.x, r1.x
    exp r2.y, r1.y
    exp r2.z, r1.z
    mad r0.xyz, r2, c9.y, c9.z
    mul r0, r5.w, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 52 instruction slots used (5 texture, 47 arithmetic)
#endif

const DWORD linear28[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020007,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0008,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x05000051, 0xa00f0009,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80040000, 0xa0000007, 0x02000001, 0x80030000,
    0xb0e40001, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000002,
    0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000006, 0x03000005,
    0x80140000, 0x80aa0000, 0xa0550006, 0x03000002, 0x80020000, 0x80550000,
    0x80aa0000, 0x02000013, 0x80040000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81aa0000, 0x03000002, 0x80080000, 0x80550000, 0xa0000007,
    0x04000004, 0x80010001, 0x80ff0000, 0xa0aa0008, 0xa0ff0008, 0x03000002,
    0x80080000, 0x80000000, 0xa0ff0007, 0x04000004, 0x80010002, 0x80550000,
    0xa0aa0008, 0xa0ff0008, 0x02000001, 0x80020002, 0xa0aa0007, 0x02000001,
    0x80020001, 0xa0aa0007, 0x02000001, 0x80030003, 0xa0e40008, 0x02000001,
    0x80030004, 0xa0c90007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801,
    0x03000042, 0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003,
    0x80e40003, 0xa0e40801, 0x03000042, 0x800f0004, 0x80e40004, 0xa0e40801,
    0x03000042, 0x800f0005, 0xb0e40000, 0xa0e40800, 0x04000012, 0x800f0006,
    0x80aa0000, 0x80e40001, 0x80e40002, 0x04000058, 0x800f0001, 0x80ff0000,
    0x80e40003, 0x80e40006, 0x04000058, 0x800f0000, 0x81000000, 0x80e40004,
    0x80e40001, 0x0200000f, 0x80010001, 0x80000000, 0x0200000f, 0x80020001,
    0x80550000, 0x0200000f, 0x80040001, 0x80aa0000, 0x03000005, 0x80070001,
    0x80e40001, 0xa0000009, 0x0200000e, 0x80010002, 0x80000001, 0x0200000e,
    0x80020002, 0x80550001, 0x0200000e, 0x80040002, 0x80aa0001, 0x04000004,
    0x80070000, 0x80e40002, 0xa0550009, 0xa0aa0009, 0x03000005, 0x800f0000,
    0x80ff0005, 0x80e40000, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear29 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0.5, -0.5, 2
    def c8, 0.0625, 0.03125, 0.416667014, 0
    def c9, 1.05499995, -0.0549999997, 0, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c7.x
    dp3 r0.x, c16, r0
    mul r0.x, r0.x, c7.y
    frc r0.x, r0.x
    add r0.x, r0.x, c7.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c7.w, c7.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c8.x, c8.y
    mad r2.x, r0.z, c8.x, c8.y
    mov r2.y, c7.y
    mov r1.y, c7.y
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    log r0.x, r4.x
    log r0.y, r4.y
    log r0.z, r4.z
    mul r0.xyz, r0, c8.z
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r4.xyz, r1, c9.x, c9.y
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 50 instruction slots used (3 texture, 47 arithmetic)
#endif

const DWORD linear29[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020007,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0008,
    0x3d800000, 0x3d000000, 0x3ed55561, 0x00000000, 0x05000051, 0xa00f0009,
    0x3f870a3d, 0xbd6147ae, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x03000005,
    0x80010000, 0x80000000, 0xa0550007, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0007, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0007, 0xa0000007,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005,
    0x03000002, 0x80010000, 0x80000000, 0xa1000006, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550006, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000007, 0x04000004, 0x80010001, 0x80000000, 0xa0000008, 0xa0550008,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000008, 0xa0550008, 0x02000001,
    0x80020002, 0xa0550007, 0x02000001, 0x80020001, 0xa0550007, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0004, 0x80550000, 0x80e40002, 0x80e40001, 0x0200000f, 0x80010000,
    0x80000004, 0x0200000f, 0x80020000, 0x80550004, 0x0200000f, 0x80040000,
    0x80aa0004, 0x03000005, 0x80070000, 0x80e40000, 0xa0aa0008, 0x0200000e,
    0x80010001, 0x80000000, 0x0200000e, 0x80020001, 0x80550000, 0x0200000e,
    0x80040001, 0x80aa0000, 0x04000004, 0x80070004, 0x80e40001, 0xa0000009,
    0xa0550009, 0x03000005, 0x800f0000, 0x80ff0003, 0x80e40004, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn linear30 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   sampler2D mask;
//   float3 params;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   params       c16      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0.0625, 0.03125, 0.5
    def c8, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c7.x
    dp3 r0.x, c16, r0
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c7.y, c7.z
    mad r2.x, r0.z, c7.y, c7.z
    mov r2.y, c7.w
    mov r1.y, c7.w
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    log r0.x, r4.x
    log r0.y, r4.y
    log r0.z, r4.z
    mul r0.xyz, r0, c8.x
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r4.xyz, r1, c8.y, c8.z
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 46 instruction slots used (3 texture, 43 arithmetic)
#endif

const DWORD linear30[] =
{
    0xffff0200, 0x003efffe, 0x42415443, 0x0000001c, 0x000000c3, 0xffff0200,
    0x00000004, 0x0000001c, 0x20000100, 0x000000bc, 0x0000006c, 0x00010003,
    0x00060001, 0x00000074, 0x00000000, 0x00000084, 0x00000002, 0x00020007,
    0x00000090, 0x00000000, 0x000000a0, 0x00000003, 0x00020001, 0x00000074,
    0x00000000, 0x000000a5, 0x00100002, 0x00420001, 0x000000ac, 0x00000000,
    0x6f6c6f63, 0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000,
    0x63617266, 0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008,
    0x00000000, 0x6b73616d, 0x72617000, 0x00736d61, 0x00030001, 0x00030001,
    0x00000001, 0x00000000, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x05000051, 0xa00f0008,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80010000, 0xa0e40010, 0x80e40000, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550001,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000002, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550002,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000003, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000004, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550004,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000005, 0x03000002, 0x80010000, 0x80000000, 0xa1000006,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550006,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000007, 0x04000004, 0x80010001, 0x80000000,
    0xa0550007, 0xa0aa0007, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550007,
    0xa0aa0007, 0x02000001, 0x80020002, 0xa0ff0007, 0x02000001, 0x80020001,
    0xa0ff0007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000,
    0xa0e40800, 0x04000012, 0x800f0004, 0x80550000, 0x80e40002, 0x80e40001,
    0x0200000f, 0x80010000, 0x80000004, 0x0200000f, 0x80020000, 0x80550004,
    0x0200000f, 0x80040000, 0x80aa0004, 0x03000005, 0x80070000, 0x80e40000,
    0xa0000008, 0x0200000e, 0x80010001, 0x80000000, 0x0200000e, 0x80020001,
    0x80550000, 0x0200000e, 0x80040001, 0x80aa0000, 0x04000004, 0x80070004,
    0x80e40001, 0xa0550008, 0xa0aa0008, 0x03000005, 0x800f0000, 0x80ff0003,
    0x80e40004, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001,
    0x800f0800, 0x80e40000, 0x0000ffff
};
const DWORD *linearShaders[] =
{
    linear0,
    linear1,
    linear2,
    NULL,
    linear4,
    linear5,
    linear6,
    NULL,
    linear8,
    linear9,
    linear10,
    NULL,
    linear12,
    linear13,
    linear14,
    NULL,
    linear16,
    linear17,
    linear18,
    NULL,
    linear20,
    linear21,
    linear22,
    NULL,
    linear24,
    linear25,
    linear26,
    NULL,
    linear28,
    linear29,
    linear30,
    NULL,
};

#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial0 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0, 0.5, -1
    def c4, 1, 0.5, 0.0625, 0.03125
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.z, c3.x
    mov r0.xy, t0
    dp3 r0.w, r0, c17
    mul r0.w, r0.w, r0.w
    mul r0.w, r0.w, c18.y
    dp3 r0.x, r0, c16
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.w
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mov r0.z, c18.z
    mad r0.y, r0.x, r0.z, -c0.x
    mul_sat r0.y, r0.y, c0.y
    mad r0.w, r0.x, r0.z, -c1.x
    mul_sat r0.w, r0.w, c1.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c2.x
    mul_sat r0.w, r0.w, c2.y
    add r0.y, r0.y, r0.w
    frc r0.w, r0.y
    add r0.y, r0.y, -r0.w
    add r1.w, r0.y, c3.x
    mad r1.x, r1.w, c4.z, c4.w
    mul r1.z, r0.x, c18.z
    mad r1.w, r0.x, r0.z, c3.w
    mad r0.x, r0.y, c4.z, c4.w
    mov r0.y, c3.z
    mov r1.y, c3.z
    mov r2.xy, c4
    mov r3.xy, c3.yzxw
    texld r4, r0, s0
    texld r5, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    lrp r6, r0.w, r5, r4
    cmp r0, r1.w, r2, r6
    cmp r0, -r1.z, r3, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 40 instruction slots used (4 texture, 36 arithmetic)
#endif

const DWORD radial0[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020003,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0004,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80040000, 0xa0000003, 0x02000001, 0x80030000,
    0xb0e40000, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000005,
    0x80080000, 0x80ff0000, 0x80ff0000, 0x03000005, 0x80080000, 0x80ff0000,
    0xa0550012, 0x03000008, 0x80010000, 0x80e40000, 0xa0e40010, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80ff0000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x02000001, 0x80040000, 0xa0aa0012, 0x04000004, 0x80020000,
    0x80000000, 0x80aa0000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000001,
    0x03000005, 0x80180000, 0x80ff0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000,
    0xa1000002, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550002, 0x03000002,
    0x80020000, 0x80550000, 0x80ff0000, 0x02000013, 0x80080000, 0x80550000,
    0x03000002, 0x80020000, 0x80550000, 0x81ff0000, 0x03000002, 0x80080001,
    0x80550000, 0xa0000003, 0x04000004, 0x80010001, 0x80ff0001, 0xa0aa0004,
    0xa0ff0004, 0x03000005, 0x80040001, 0x80000000, 0xa0aa0012, 0x04000004,
    0x80080001, 0x80000000, 0x80aa0000, 0xa0ff0003, 0x04000004, 0x80010000,
    0x80550000, 0xa0aa0004, 0xa0ff0004, 0x02000001, 0x80020000, 0xa0aa0003,
    0x02000001, 0x80020001, 0xa0aa0003, 0x02000001, 0x80030002, 0xa0e40004,
    0x02000001, 0x80030003, 0xa0c90003, 0x03000042, 0x800f0004, 0x80e40000,
    0xa0e40800, 0x03000042, 0x800f0005, 0x80e40001, 0xa0e40800, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0003, 0x80e40003,
    0xa0e40800, 0x04000012, 0x800f0006, 0x80ff0000, 0x80e40005, 0x80e40004,
    0x04000058, 0x800f0000, 0x80ff0001, 0x80e40002, 0x80e40006, 0x04000058,
    0x800f0000, 0x81aa0001, 0x80e40003, 0x80e40000, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial1 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0.5, -0.5, 2
    def c4, 0.0625, 0.03125, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    mul r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c4.x, c4.y
    mad r2.x, r0.z, c4.x, c4.y
    mov r2.y, c3.y
    mov r1.y, c3.y
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    mul r0, r3, v0
    mov oC0, r0

// approximately 37 instruction slots used (2 texture, 35 arithmetic)
#endif

const DWORD radial1[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020003,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0004,
    0x3d800000, 0x3d000000, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x03000005,
    0x80010000, 0x80000000, 0xa0550003, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0003, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000002, 0x80010000, 0x80000000, 0xa1000002, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550002, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000003, 0x04000004, 0x80010001, 0x80000000, 0xa0000004, 0xa0550004,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000004, 0xa0550004, 0x02000001,
    0x80020002, 0xa0550003, 0x02000001, 0x80020001, 0xa0550003, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40800, 0x04000012, 0x800f0003, 0x80550000, 0x80e40002, 0x80e40001,
    0x03000005, 0x800f0000, 0x80e40003, 0x90e40000, 0x02000001, 0x800f0800,
    0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial2 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0.0625, 0.03125, 0.5
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c3.y, c3.z
    mad r2.x, r0.z, c3.y, c3.z
    mov r2.y, c3.w
    mov r1.y, c3.w
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    mul r0, r3, v0
    mov oC0, r0

// approximately 33 instruction slots used (2 texture, 31 arithmetic)
#endif

const DWORD radial2[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020003,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000002, 0x80010000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550002,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000003, 0x04000004, 0x80010001, 0x80000000,
    0xa0550003, 0xa0aa0003, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550003,
    0xa0aa0003, 0x02000001, 0x80020002, 0xa0ff0003, 0x02000001, 0x80020001,
    0xa0ff0003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x04000012, 0x800f0003, 0x80550000,
    0x80e40002, 0x80e40001, 0x03000005, 0x800f0000, 0x80e40003, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial4 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0, 0.5, -1
    def c8, 1, 0.5, 0.0625, 0.03125
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.z, c7.x
    mov r0.xy, t0
    dp3 r0.w, r0, c17
    mul r0.w, r0.w, r0.w
    mul r0.w, r0.w, c18.y
    dp3 r0.x, r0, c16
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.w
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mov r0.z, c18.z
    mad r0.y, r0.x, r0.z, -c0.x
    mul_sat r0.y, r0.y, c0.y
    mad r0.w, r0.x, r0.z, -c1.x
    mul_sat r0.w, r0.w, c1.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c2.x
    mul_sat r0.w, r0.w, c2.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c3.x
    mul_sat r0.w, r0.w, c3.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c4.x
    mul_sat r0.w, r0.w, c4.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c5.x
    mul_sat r0.w, r0.w, c5.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c6.x
    mul_sat r0.w, r0.w, c6.y
    add r0.y, r0.y, r0.w
    frc r0.w, r0.y
    add r0.y, r0.y, -r0.w
    add r1.w, r0.y, c7.x
    mad r1.x, r1.w, c8.z, c8.w
    mul r1.z, r0.x, c18.z
    mad r1.w, r0.x, r0.z, c7.w
    mad r0.x, r0.y, c8.z, c8.w
    mov r0.y, c7.z
    mov r1.y, c7.z
    mov r2.xy, c8
    mov r3.xy, c7.yzxw
    texld r4, r0, s0
    texld r5, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    lrp r6, r0.w, r5, r4
    cmp r0, r1.w, r2, r6
    cmp r0, -r1.z, r3, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 52 instruction slots used (4 texture, 48 arithmetic)
#endif

const DWORD radial4[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020007,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0008,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80040000, 0xa0000007, 0x02000001, 0x80030000,
    0xb0e40000, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000005,
    0x80080000, 0x80ff0000, 0x80ff0000, 0x03000005, 0x80080000, 0x80ff0000,
    0xa0550012, 0x03000008, 0x80010000, 0x80e40000, 0xa0e40010, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80ff0000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x02000001, 0x80040000, 0xa0aa0012, 0x04000004, 0x80020000,
    0x80000000, 0x80aa0000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000001,
    0x03000005, 0x80180000, 0x80ff0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000,
    0xa1000002, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550002, 0x03000002,
    0x80020000, 0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000,
    0x80aa0000, 0xa1000003, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80ff0000, 0x04000004, 0x80080000,
    0x80000000, 0x80aa0000, 0xa1000004, 0x03000005, 0x80180000, 0x80ff0000,
    0xa0550004, 0x03000002, 0x80020000, 0x80550000, 0x80ff0000, 0x04000004,
    0x80080000, 0x80000000, 0x80aa0000, 0xa1000005, 0x03000005, 0x80180000,
    0x80ff0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80ff0000,
    0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000006, 0x03000005,
    0x80180000, 0x80ff0000, 0xa0550006, 0x03000002, 0x80020000, 0x80550000,
    0x80ff0000, 0x02000013, 0x80080000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81ff0000, 0x03000002, 0x80080001, 0x80550000, 0xa0000007,
    0x04000004, 0x80010001, 0x80ff0001, 0xa0aa0008, 0xa0ff0008, 0x03000005,
    0x80040001, 0x80000000, 0xa0aa0012, 0x04000004, 0x80080001, 0x80000000,
    0x80aa0000, 0xa0ff0007, 0x04000004, 0x80010000, 0x80550000, 0xa0aa0008,
    0xa0ff0008, 0x02000001, 0x80020000, 0xa0aa0007, 0x02000001, 0x80020001,
    0xa0aa0007, 0x02000001, 0x80030002, 0xa0e40008, 0x02000001, 0x80030003,
    0xa0c90007, 0x03000042, 0x800f0004, 0x80e40000, 0xa0e40800, 0x03000042,
    0x800f0005, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002, 0x80e40002,
    0xa0e40800, 0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800, 0x04000012,
    0x800f0006, 0x80ff0000, 0x80e40005, 0x80e40004, 0x04000058, 0x800f0000,
    0x80ff0001, 0x80e40002, 0x80e40006, 0x04000058, 0x800f0000, 0x81aa0001,
    0x80e40003, 0x80e40000, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial5 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0.5, -0.5, 2
    def c8, 0.0625, 0.03125, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c7.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    mul r0.x, r0.x, c7.y
    frc r0.x, r0.x
    add r0.x, r0.x, c7.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c7.w, c7.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c8.x, c8.y
    mad r2.x, r0.z, c8.x, c8.y
    mov r2.y, c7.y
    mov r1.y, c7.y
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    mul r0, r3, v0
    mov oC0, r0

// approximately 49 instruction slots used (2 texture, 47 arithmetic)
#endif

const DWORD radial5[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020007,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0008,
    0x3d800000, 0x3d000000, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x03000005,
    0x80010000, 0x80000000, 0xa0550007, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0007, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0007, 0xa0000007,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005,
    0x03000002, 0x80010000, 0x80000000, 0xa1000006, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550006, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000007, 0x04000004, 0x80010001, 0x80000000, 0xa0000008, 0xa0550008,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000008, 0xa0550008, 0x02000001,
    0x80020002, 0xa0550007, 0x02000001, 0x80020001, 0xa0550007, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40800, 0x04000012, 0x800f0003, 0x80550000, 0x80e40002, 0x80e40001,
    0x03000005, 0x800f0000, 0x80e40003, 0x90e40000, 0x02000001, 0x800f0800,
    0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial6 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0.0625, 0.03125, 0.5
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c7.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c7.y, c7.z
    mad r2.x, r0.z, c7.y, c7.z
    mov r2.y, c7.w
    mov r1.y, c7.w
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    mul r0, r3, v0
    mov oC0, r0

// approximately 45 instruction slots used (2 texture, 43 arithmetic)
#endif

const DWORD radial6[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020007,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550001,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000002, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550002,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000003, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000004, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550004,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000005, 0x03000002, 0x80010000, 0x80000000, 0xa1000006,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550006,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000007, 0x04000004, 0x80010001, 0x80000000,
    0xa0550007, 0xa0aa0007, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550007,
    0xa0aa0007, 0x02000001, 0x80020002, 0xa0ff0007, 0x02000001, 0x80020001,
    0xa0ff0007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x04000012, 0x800f0003, 0x80550000,
    0x80e40002, 0x80e40001, 0x03000005, 0x800f0000, 0x80e40003, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial8 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0, 0.5, -1
    def c4, 1, 0.5, 0.0625, 0.03125
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.z, c3.x
    mov r0.xy, t1
    dp3 r0.w, r0, c17
    mul r0.w, r0.w, r0.w
    mul r0.w, r0.w, c18.y
    dp3 r0.x, r0, c16
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.w
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mov r0.z, c18.z
    mad r0.y, r0.x, r0.z, -c0.x
    mul_sat r0.y, r0.y, c0.y
    mad r0.w, r0.x, r0.z, -c1.x
    mul_sat r0.w, r0.w, c1.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c2.x
    mul_sat r0.w, r0.w, c2.y
    add r0.y, r0.y, r0.w
    frc r0.w, r0.y
    add r0.y, r0.y, -r0.w
    add r1.w, r0.y, c3.x
    mad r1.x, r1.w, c4.z, c4.w
    mul r1.z, r0.x, c18.z
    mad r1.w, r0.x, r0.z, c3.w
    mad r0.x, r0.y, c4.z, c4.w
    mov r0.y, c3.z
    mov r1.y, c3.z
    mov r2.xy, c4
    mov r3.xy, c3.yzxw
    texld r4, r0, s1
    texld r5, r1, s1
    texld r2, r2, s1
    texld r3, r3, s1
    texld r6, t0, s0
    lrp r7, r0.w, r5, r4
    cmp r0, r1.w, r2, r7
    cmp r0, -r1.z, r3, r0
    mul r0, r6.w, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 42 instruction slots used (5 texture, 37 arithmetic)
#endif

const DWORD radial8[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020003,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0004,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80040000, 0xa0000003, 0x02000001, 0x80030000,
    0xb0e40001, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000005,
    0x80080000, 0x80ff0000, 0x80ff0000, 0x03000005, 0x80080000, 0x80ff0000,
    0xa0550012, 0x03000008, 0x80010000, 0x80e40000, 0xa0e40010, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80ff0000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x02000001, 0x80040000, 0xa0aa0012, 0x04000004, 0x80020000,
    0x80000000, 0x80aa0000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000001,
    0x03000005, 0x80180000, 0x80ff0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000,
    0xa1000002, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550002, 0x03000002,
    0x80020000, 0x80550000, 0x80ff0000, 0x02000013, 0x80080000, 0x80550000,
    0x03000002, 0x80020000, 0x80550000, 0x81ff0000, 0x03000002, 0x80080001,
    0x80550000, 0xa0000003, 0x04000004, 0x80010001, 0x80ff0001, 0xa0aa0004,
    0xa0ff0004, 0x03000005, 0x80040001, 0x80000000, 0xa0aa0012, 0x04000004,
    0x80080001, 0x80000000, 0x80aa0000, 0xa0ff0003, 0x04000004, 0x80010000,
    0x80550000, 0xa0aa0004, 0xa0ff0004, 0x02000001, 0x80020000, 0xa0aa0003,
    0x02000001, 0x80020001, 0xa0aa0003, 0x02000001, 0x80030002, 0xa0e40004,
    0x02000001, 0x80030003, 0xa0c90003, 0x03000042, 0x800f0004, 0x80e40000,
    0xa0e40801, 0x03000042, 0x800f0005, 0x80e40001, 0xa0e40801, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0003, 0x80e40003,
    0xa0e40801, 0x03000042, 0x800f0006, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0007, 0x80ff0000, 0x80e40005, 0x80e40004, 0x04000058, 0x800f0000,
    0x80ff0001, 0x80e40002, 0x80e40007, 0x04000058, 0x800f0000, 0x81aa0001,
    0x80e40003, 0x80e40000, 0x03000005, 0x800f0000, 0x80ff0006, 0x80e40000,
    0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800,
    0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial9 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0.5, -0.5, 2
    def c4, 0.0625, 0.03125, 0, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    mul r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c4.x, c4.y
    mad r2.x, r0.z, c4.x, c4.y
    mov r2.y, c3.y
    mov r1.y, c3.y
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 39 instruction slots used (3 texture, 36 arithmetic)
#endif

const DWORD radial9[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020003,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0004,
    0x3d800000, 0x3d000000, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x03000005,
    0x80010000, 0x80000000, 0xa0550003, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0003, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000002, 0x80010000, 0x80000000, 0xa1000002, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550002, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000003, 0x04000004, 0x80010001, 0x80000000, 0xa0000004, 0xa0550004,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000004, 0xa0550004, 0x02000001,
    0x80020002, 0xa0550003, 0x02000001, 0x80020001, 0xa0550003, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0004, 0x80550000, 0x80e40002, 0x80e40001, 0x03000005, 0x800f0000,
    0x80ff0003, 0x80e40004, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial10 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0.0625, 0.03125, 0.5
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c3.y, c3.z
    mad r2.x, r0.z, c3.y, c3.z
    mov r2.y, c3.w
    mov r1.y, c3.w
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 35 instruction slots used (3 texture, 32 arithmetic)
#endif

const DWORD radial10[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020003,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000002, 0x80010000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550002,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000003, 0x04000004, 0x80010001, 0x80000000,
    0xa0550003, 0xa0aa0003, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550003,
    0xa0aa0003, 0x02000001, 0x80020002, 0xa0ff0003, 0x02000001, 0x80020001,
    0xa0ff0003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000,
    0xa0e40800, 0x04000012, 0x800f0004, 0x80550000, 0x80e40002, 0x80e40001,
    0x03000005, 0x800f0000, 0x80ff0003, 0x80e40004, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial12 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0, 0.5, -1
    def c8, 1, 0.5, 0.0625, 0.03125
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.z, c7.x
    mov r0.xy, t1
    dp3 r0.w, r0, c17
    mul r0.w, r0.w, r0.w
    mul r0.w, r0.w, c18.y
    dp3 r0.x, r0, c16
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.w
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mov r0.z, c18.z
    mad r0.y, r0.x, r0.z, -c0.x
    mul_sat r0.y, r0.y, c0.y
    mad r0.w, r0.x, r0.z, -c1.x
    mul_sat r0.w, r0.w, c1.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c2.x
    mul_sat r0.w, r0.w, c2.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c3.x
    mul_sat r0.w, r0.w, c3.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c4.x
    mul_sat r0.w, r0.w, c4.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c5.x
    mul_sat r0.w, r0.w, c5.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c6.x
    mul_sat r0.w, r0.w, c6.y
    add r0.y, r0.y, r0.w
    frc r0.w, r0.y
    add r0.y, r0.y, -r0.w
    add r1.w, r0.y, c7.x
    mad r1.x, r1.w, c8.z, c8.w
    mul r1.z, r0.x, c18.z
    mad r1.w, r0.x, r0.z, c7.w
    mad r0.x, r0.y, c8.z, c8.w
    mov r0.y, c7.z
    mov r1.y, c7.z
    mov r2.xy, c8
    mov r3.xy, c7.yzxw
    texld r4, r0, s1
    texld r5, r1, s1
    texld r2, r2, s1
    texld r3, r3, s1
    texld r6, t0, s0
    lrp r7, r0.w, r5, r4
    cmp r0, r1.w, r2, r7
    cmp r0, -r1.z, r3, r0
    mul r0, r6.w, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 54 instruction slots used (5 texture, 49 arithmetic)
#endif

const DWORD radial12[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020007,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0008,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80040000, 0xa0000007, 0x02000001, 0x80030000,
    0xb0e40001, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000005,
    0x80080000, 0x80ff0000, 0x80ff0000, 0x03000005, 0x80080000, 0x80ff0000,
    0xa0550012, 0x03000008, 0x80010000, 0x80e40000, 0xa0e40010, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80ff0000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x02000001, 0x80040000, 0xa0aa0012, 0x04000004, 0x80020000,
    0x80000000, 0x80aa0000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000001,
    0x03000005, 0x80180000, 0x80ff0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000,
    0xa1000002, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550002, 0x03000002,
    0x80020000, 0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000,
    0x80aa0000, 0xa1000003, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80ff0000, 0x04000004, 0x80080000,
    0x80000000, 0x80aa0000, 0xa1000004, 0x03000005, 0x80180000, 0x80ff0000,
    0xa0550004, 0x03000002, 0x80020000, 0x80550000, 0x80ff0000, 0x04000004,
    0x80080000, 0x80000000, 0x80aa0000, 0xa1000005, 0x03000005, 0x80180000,
    0x80ff0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80ff0000,
    0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000006, 0x03000005,
    0x80180000, 0x80ff0000, 0xa0550006, 0x03000002, 0x80020000, 0x80550000,
    0x80ff0000, 0x02000013, 0x80080000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81ff0000, 0x03000002, 0x80080001, 0x80550000, 0xa0000007,
    0x04000004, 0x80010001, 0x80ff0001, 0xa0aa0008, 0xa0ff0008, 0x03000005,
    0x80040001, 0x80000000, 0xa0aa0012, 0x04000004, 0x80080001, 0x80000000,
    0x80aa0000, 0xa0ff0007, 0x04000004, 0x80010000, 0x80550000, 0xa0aa0008,
    0xa0ff0008, 0x02000001, 0x80020000, 0xa0aa0007, 0x02000001, 0x80020001,
    0xa0aa0007, 0x02000001, 0x80030002, 0xa0e40008, 0x02000001, 0x80030003,
    0xa0c90007, 0x03000042, 0x800f0004, 0x80e40000, 0xa0e40801, 0x03000042,
    0x800f0005, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0002, 0x80e40002,
    0xa0e40801, 0x03000042, 0x800f0003, 0x80e40003, 0xa0e40801, 0x03000042,
    0x800f0006, 0xb0e40000, 0xa0e40800, 0x04000012, 0x800f0007, 0x80ff0000,
    0x80e40005, 0x80e40004, 0x04000058, 0x800f0000, 0x80ff0001, 0x80e40002,
    0x80e40007, 0x04000058, 0x800f0000, 0x81aa0001, 0x80e40003, 0x80e40000,
    0x03000005, 0x800f0000, 0x80ff0006, 0x80e40000, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial13 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0.5, -0.5, 2
    def c8, 0.0625, 0.03125, 0, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c7.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    mul r0.x, r0.x, c7.y
    frc r0.x, r0.x
    add r0.x, r0.x, c7.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c7.w, c7.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c8.x, c8.y
    mad r2.x, r0.z, c8.x, c8.y
    mov r2.y, c7.y
    mov r1.y, c7.y
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 51 instruction slots used (3 texture, 48 arithmetic)
#endif

const DWORD radial13[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020007,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0008,
    0x3d800000, 0x3d000000, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x03000005,
    0x80010000, 0x80000000, 0xa0550007, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0007, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0007, 0xa0000007,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005,
    0x03000002, 0x80010000, 0x80000000, 0xa1000006, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550006, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000007, 0x04000004, 0x80010001, 0x80000000, 0xa0000008, 0xa0550008,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000008, 0xa0550008, 0x02000001,
    0x80020002, 0xa0550007, 0x02000001, 0x80020001, 0xa0550007, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0004, 0x80550000, 0x80e40002, 0x80e40001, 0x03000005, 0x800f0000,
    0x80ff0003, 0x80e40004, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000,
    0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial14 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0.0625, 0.03125, 0.5
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c7.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c7.y, c7.z
    mad r2.x, r0.z, c7.y, c7.z
    mov r2.y, c7.w
    mov r1.y, c7.w
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 47 instruction slots used (3 texture, 44 arithmetic)
#endif

const DWORD radial14[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020007,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550001,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000002, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550002,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000003, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000004, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550004,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000005, 0x03000002, 0x80010000, 0x80000000, 0xa1000006,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550006,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000007, 0x04000004, 0x80010001, 0x80000000,
    0xa0550007, 0xa0aa0007, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550007,
    0xa0aa0007, 0x02000001, 0x80020002, 0xa0ff0007, 0x02000001, 0x80020001,
    0xa0ff0007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000,
    0xa0e40800, 0x04000012, 0x800f0004, 0x80550000, 0x80e40002, 0x80e40001,
    0x03000005, 0x800f0000, 0x80ff0003, 0x80e40004, 0x03000005, 0x800f0000,
    0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial16 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0, 0.5, -1
    def c4, 1, 0.5, 0.0625, 0.03125
    def c5, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.z, c3.x
    mov r0.xy, t0
    dp3 r0.w, r0, c17
    mul r0.w, r0.w, r0.w
    mul r0.w, r0.w, c18.y
    dp3 r0.x, r0, c16
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.w
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mov r0.z, c18.z
    mad r0.y, r0.x, r0.z, -c0.x
    mul_sat r0.y, r0.y, c0.y
    mad r0.w, r0.x, r0.z, -c1.x
    mul_sat r0.w, r0.w, c1.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c2.x
    mul_sat r0.w, r0.w, c2.y
    add r0.y, r0.y, r0.w
    frc r0.w, r0.y
    add r0.y, r0.y, -r0.w
    add r1.w, r0.y, c3.x
    mad r1.x, r1.w, c4.z, c4.w
    mul r1.z, r0.x, c18.z
    mad r1.w, r0.x, r0.z, c3.w
    mad r0.x, r0.y, c4.z, c4.w
    mov r0.y, c3.z
    mov r1.y, c3.z
    mov r2.xy, c4
    mov r3.xy, c3.yzxw
    texld r4, r0, s0
    texld r5, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    lrp r6, r0.w, r5, r4
    cmp r0, r1.w, r2, r6
    cmp r0, -r1.z, r3, r0
    log r1.x, r0.x
    log r1.y, r0.y
    log r1.z, r0.z
    mul r1.xyz, r1, c5.x
    exp r2.x, r1.x
    exp r2.y, r1.y
    exp r2.z, r1.z
    mad r0.xyz, r2, c5.y, c5.z
    mul r0, r0, v0
    mov oC0, r0

// approximately 48 instruction slots used (4 texture, 44 arithmetic)
#endif

const DWORD radial16[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020003,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0004,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x05000051, 0xa00f0005,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80040000, 0xa0000003, 0x02000001, 0x80030000,
    0xb0e40000, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000005,
    0x80080000, 0x80ff0000, 0x80ff0000, 0x03000005, 0x80080000, 0x80ff0000,
    0xa0550012, 0x03000008, 0x80010000, 0x80e40000, 0xa0e40010, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80ff0000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x02000001, 0x80040000, 0xa0aa0012, 0x04000004, 0x80020000,
    0x80000000, 0x80aa0000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000001,
    0x03000005, 0x80180000, 0x80ff0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000,
    0xa1000002, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550002, 0x03000002,
    0x80020000, 0x80550000, 0x80ff0000, 0x02000013, 0x80080000, 0x80550000,
    0x03000002, 0x80020000, 0x80550000, 0x81ff0000, 0x03000002, 0x80080001,
    0x80550000, 0xa0000003, 0x04000004, 0x80010001, 0x80ff0001, 0xa0aa0004,
    0xa0ff0004, 0x03000005, 0x80040001, 0x80000000, 0xa0aa0012, 0x04000004,
    0x80080001, 0x80000000, 0x80aa0000, 0xa0ff0003, 0x04000004, 0x80010000,
    0x80550000, 0xa0aa0004, 0xa0ff0004, 0x02000001, 0x80020000, 0xa0aa0003,
    0x02000001, 0x80020001, 0xa0aa0003, 0x02000001, 0x80030002, 0xa0e40004,
    0x02000001, 0x80030003, 0xa0c90003, 0x03000042, 0x800f0004, 0x80e40000,
    0xa0e40800, 0x03000042, 0x800f0005, 0x80e40001, 0xa0e40800, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0003, 0x80e40003,
    0xa0e40800, 0x04000012, 0x800f0006, 0x80ff0000, 0x80e40005, 0x80e40004,
    0x04000058, 0x800f0000, 0x80ff0001, 0x80e40002, 0x80e40006, 0x04000058,
    0x800f0000, 0x81aa0001, 0x80e40003, 0x80e40000, 0x0200000f, 0x80010001,
    0x80000000, 0x0200000f, 0x80020001, 0x80550000, 0x0200000f, 0x80040001,
    0x80aa0000, 0x03000005, 0x80070001, 0x80e40001, 0xa0000005, 0x0200000e,
    0x80010002, 0x80000001, 0x0200000e, 0x80020002, 0x80550001, 0x0200000e,
    0x80040002, 0x80aa0001, 0x04000004, 0x80070000, 0x80e40002, 0xa0550005,
    0xa0aa0005, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001,
    0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial17 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0.5, -0.5, 2
    def c4, 0.0625, 0.03125, 0.416667014, 0
    def c5, 1.05499995, -0.0549999997, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    mul r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c4.x, c4.y
    mad r2.x, r0.z, c4.x, c4.y
    mov r2.y, c3.y
    mov r1.y, c3.y
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    log r0.x, r3.x
    log r0.y, r3.y
    log r0.z, r3.z
    mul r0.xyz, r0, c4.z
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r3.xyz, r1, c5.x, c5.y
    mul r0, r3, v0
    mov oC0, r0

// approximately 45 instruction slots used (2 texture, 43 arithmetic)
#endif

const DWORD radial17[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020003,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0004,
    0x3d800000, 0x3d000000, 0x3ed55561, 0x00000000, 0x05000051, 0xa00f0005,
    0x3f870a3d, 0xbd6147ae, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x03000005,
    0x80010000, 0x80000000, 0xa0550003, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0003, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000002, 0x80010000, 0x80000000, 0xa1000002, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550002, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000003, 0x04000004, 0x80010001, 0x80000000, 0xa0000004, 0xa0550004,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000004, 0xa0550004, 0x02000001,
    0x80020002, 0xa0550003, 0x02000001, 0x80020001, 0xa0550003, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40800, 0x04000012, 0x800f0003, 0x80550000, 0x80e40002, 0x80e40001,
    0x0200000f, 0x80010000, 0x80000003, 0x0200000f, 0x80020000, 0x80550003,
    0x0200000f, 0x80040000, 0x80aa0003, 0x03000005, 0x80070000, 0x80e40000,
    0xa0aa0004, 0x0200000e, 0x80010001, 0x80000000, 0x0200000e, 0x80020001,
    0x80550000, 0x0200000e, 0x80040001, 0x80aa0000, 0x04000004, 0x80070003,
    0x80e40001, 0xa0000005, 0xa0550005, 0x03000005, 0x800f0000, 0x80e40003,
    0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial18 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c3, 1, 0.0625, 0.03125, 0.5
    def c4, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c3.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c3.y, c3.z
    mad r2.x, r0.z, c3.y, c3.z
    mov r2.y, c3.w
    mov r1.y, c3.w
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    log r0.x, r3.x
    log r0.y, r3.y
    log r0.z, r3.z
    mul r0.xyz, r0, c4.x
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r3.xyz, r1, c4.y, c4.z
    mul r0, r3, v0
    mov oC0, r0

// approximately 41 instruction slots used (2 texture, 39 arithmetic)
#endif

const DWORD radial18[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020003,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x05000051, 0xa00f0004,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000002, 0x80010000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550002,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000003, 0x04000004, 0x80010001, 0x80000000,
    0xa0550003, 0xa0aa0003, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550003,
    0xa0aa0003, 0x02000001, 0x80020002, 0xa0ff0003, 0x02000001, 0x80020001,
    0xa0ff0003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x04000012, 0x800f0003, 0x80550000,
    0x80e40002, 0x80e40001, 0x0200000f, 0x80010000, 0x80000003, 0x0200000f,
    0x80020000, 0x80550003, 0x0200000f, 0x80040000, 0x80aa0003, 0x03000005,
    0x80070000, 0x80e40000, 0xa0000004, 0x0200000e, 0x80010001, 0x80000000,
    0x0200000e, 0x80020001, 0x80550000, 0x0200000e, 0x80040001, 0x80aa0000,
    0x04000004, 0x80070003, 0x80e40001, 0xa0550004, 0xa0aa0004, 0x03000005,
    0x800f0000, 0x80e40003, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial20 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0, 0.5, -1
    def c8, 1, 0.5, 0.0625, 0.03125
    def c9, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.z, c7.x
    mov r0.xy, t0
    dp3 r0.w, r0, c17
    mul r0.w, r0.w, r0.w
    mul r0.w, r0.w, c18.y
    dp3 r0.x, r0, c16
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.w
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mov r0.z, c18.z
    mad r0.y, r0.x, r0.z, -c0.x
    mul_sat r0.y, r0.y, c0.y
    mad r0.w, r0.x, r0.z, -c1.x
    mul_sat r0.w, r0.w, c1.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c2.x
    mul_sat r0.w, r0.w, c2.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c3.x
    mul_sat r0.w, r0.w, c3.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c4.x
    mul_sat r0.w, r0.w, c4.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c5.x
    mul_sat r0.w, r0.w, c5.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c6.x
    mul_sat r0.w, r0.w, c6.y
    add r0.y, r0.y, r0.w
    frc r0.w, r0.y
    add r0.y, r0.y, -r0.w
    add r1.w, r0.y, c7.x
    mad r1.x, r1.w, c8.z, c8.w
    mul r1.z, r0.x, c18.z
    mad r1.w, r0.x, r0.z, c7.w
    mad r0.x, r0.y, c8.z, c8.w
    mov r0.y, c7.z
    mov r1.y, c7.z
    mov r2.xy, c8
    mov r3.xy, c7.yzxw
    texld r4, r0, s0
    texld r5, r1, s0
    texld r2, r2, s0
    texld r3, r3, s0
    lrp r6, r0.w, r5, r4
    cmp r0, r1.w, r2, r6
    cmp r0, -r1.z, r3, r0
    log r1.x, r0.x
    log r1.y, r0.y
    log r1.z, r0.z
    mul r1.xyz, r1, c9.x
    exp r2.x, r1.x
    exp r2.y, r1.y
    exp r2.z, r1.z
    mad r0.xyz, r2, c9.y, c9.z
    mul r0, r0, v0
    mov oC0, r0

// approximately 60 instruction slots used (4 texture, 56 arithmetic)
#endif

const DWORD radial20[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020007,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0008,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x05000051, 0xa00f0009,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80040000, 0xa0000007, 0x02000001, 0x80030000,
    0xb0e40000, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000005,
    0x80080000, 0x80ff0000, 0x80ff0000, 0x03000005, 0x80080000, 0x80ff0000,
    0xa0550012, 0x03000008, 0x80010000, 0x80e40000, 0xa0e40010, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80ff0000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x02000001, 0x80040000, 0xa0aa0012, 0x04000004, 0x80020000,
    0x80000000, 0x80aa0000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000001,
    0x03000005, 0x80180000, 0x80ff0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000,
    0xa1000002, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550002, 0x03000002,
    0x80020000, 0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000,
    0x80aa0000, 0xa1000003, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80ff0000, 0x04000004, 0x80080000,
    0x80000000, 0x80aa0000, 0xa1000004, 0x03000005, 0x80180000, 0x80ff0000,
    0xa0550004, 0x03000002, 0x80020000, 0x80550000, 0x80ff0000, 0x04000004,
    0x80080000, 0x80000000, 0x80aa0000, 0xa1000005, 0x03000005, 0x80180000,
    0x80ff0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80ff0000,
    0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000006, 0x03000005,
    0x80180000, 0x80ff0000, 0xa0550006, 0x03000002, 0x80020000, 0x80550000,
    0x80ff0000, 0x02000013, 0x80080000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81ff0000, 0x03000002, 0x80080001, 0x80550000, 0xa0000007,
    0x04000004, 0x80010001, 0x80ff0001, 0xa0aa0008, 0xa0ff0008, 0x03000005,
    0x80040001, 0x80000000, 0xa0aa0012, 0x04000004, 0x80080001, 0x80000000,
    0x80aa0000, 0xa0ff0007, 0x04000004, 0x80010000, 0x80550000, 0xa0aa0008,
    0xa0ff0008, 0x02000001, 0x80020000, 0xa0aa0007, 0x02000001, 0x80020001,
    0xa0aa0007, 0x02000001, 0x80030002, 0xa0e40008, 0x02000001, 0x80030003,
    0xa0c90007, 0x03000042, 0x800f0004, 0x80e40000, 0xa0e40800, 0x03000042,
    0x800f0005, 0x80e40001, 0xa0e40800, 0x03000042, 0x800f0002, 0x80e40002,
    0xa0e40800, 0x03000042, 0x800f0003, 0x80e40003, 0xa0e40800, 0x04000012,
    0x800f0006, 0x80ff0000, 0x80e40005, 0x80e40004, 0x04000058, 0x800f0000,
    0x80ff0001, 0x80e40002, 0x80e40006, 0x04000058, 0x800f0000, 0x81aa0001,
    0x80e40003, 0x80e40000, 0x0200000f, 0x80010001, 0x80000000, 0x0200000f,
    0x80020001, 0x80550000, 0x0200000f, 0x80040001, 0x80aa0000, 0x03000005,
    0x80070001, 0x80e40001, 0xa0000009, 0x0200000e, 0x80010002, 0x80000001,
    0x0200000e, 0x80020002, 0x80550001, 0x0200000e, 0x80040002, 0x80aa0001,
    0x04000004, 0x80070000, 0x80e40002, 0xa0550009, 0xa0aa0009, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial21 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0.5, -0.5, 2
    def c8, 0.0625, 0.03125, 0.416667014, 0
    def c9, 1.05499995, -0.0549999997, 0, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c7.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    mul r0.x, r0.x, c7.y
    frc r0.x, r0.x
    add r0.x, r0.x, c7.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c7.w, c7.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c8.x, c8.y
    mad r2.x, r0.z, c8.x, c8.y
    mov r2.y, c7.y
    mov r1.y, c7.y
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    log r0.x, r3.x
    log r0.y, r3.y
    log r0.z, r3.z
    mul r0.xyz, r0, c8.z
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r3.xyz, r1, c9.x, c9.y
    mul r0, r3, v0
    mov oC0, r0

// approximately 57 instruction slots used (2 texture, 55 arithmetic)
#endif

const DWORD radial21[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020007,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0008,
    0x3d800000, 0x3d000000, 0x3ed55561, 0x00000000, 0x05000051, 0xa00f0009,
    0x3f870a3d, 0xbd6147ae, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x03000005,
    0x80010000, 0x80000000, 0xa0550007, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0007, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0007, 0xa0000007,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005,
    0x03000002, 0x80010000, 0x80000000, 0xa1000006, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550006, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000007, 0x04000004, 0x80010001, 0x80000000, 0xa0000008, 0xa0550008,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000008, 0xa0550008, 0x02000001,
    0x80020002, 0xa0550007, 0x02000001, 0x80020001, 0xa0550007, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40800, 0x04000012, 0x800f0003, 0x80550000, 0x80e40002, 0x80e40001,
    0x0200000f, 0x80010000, 0x80000003, 0x0200000f, 0x80020000, 0x80550003,
    0x0200000f, 0x80040000, 0x80aa0003, 0x03000005, 0x80070000, 0x80e40000,
    0xa0aa0008, 0x0200000e, 0x80010001, 0x80000000, 0x0200000e, 0x80020001,
    0x80550000, 0x0200000e, 0x80040001, 0x80aa0000, 0x04000004, 0x80070003,
    0x80e40001, 0xa0000009, 0xa0550009, 0x03000005, 0x800f0000, 0x80e40003,
    0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial22 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   colors       s0       1
//

    ps_2_0
    def c7, 1, 0.0625, 0.03125, 0.5
    def c8, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl v0
    dcl_2d s0
    mov r0.xy, t0
    mov r0.z, c7.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c7.y, c7.z
    mad r2.x, r0.z, c7.y, c7.z
    mov r2.y, c7.w
    mov r1.y, c7.w
    texld r2, r2, s0
    texld r1, r1, s0
    lrp r3, r0.y, r2, r1
    log r0.x, r3.x
    log r0.y, r3.y
    log r0.z, r3.z
    mul r0.xyz, r0, c8.x
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r3.xyz, r1, c8.y, c8.z
    mul r0, r3, v0
    mov oC0, r0

// approximately 53 instruction slots used (2 texture, 51 arithmetic)
#endif

const DWORD radial22[] =
{
    0xffff0200, 0x0044fffe, 0x42415443, 0x0000001c, 0x000000da, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000d3, 0x00000080, 0x00000003,
    0x00020001, 0x00000088, 0x00000000, 0x00000098, 0x00000002, 0x00020007,
    0x000000a4, 0x00000000, 0x000000b4, 0x00100002, 0x00420001, 0x000000b8,
    0x00000000, 0x000000c8, 0x00110002, 0x00460001, 0x000000b8, 0x00000000,
    0x000000cb, 0x00120002, 0x004a0001, 0x000000b8, 0x00000000, 0x6f6c6f63,
    0xab007372, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266,
    0x6e6f6974, 0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000,
    0xab00306d, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x7000316d,
    0x61636572, 0x7000636c, 0x5f325f73, 0x694d0030, 0x736f7263, 0x2074666f,
    0x20295228, 0x4c534c48, 0x61685320, 0x20726564, 0x706d6f43, 0x72656c69,
    0x312e3920, 0x34392e39, 0x31322e39, 0xab003131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x05000051, 0xa00f0008,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0x900f0000, 0x0200001f, 0x90000000,
    0xa00f0800, 0x02000001, 0x80030000, 0xb0e40000, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550001,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000002, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550002,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000003, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000004, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550004,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000005, 0x03000002, 0x80010000, 0x80000000, 0xa1000006,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550006,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000007, 0x04000004, 0x80010001, 0x80000000,
    0xa0550007, 0xa0aa0007, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550007,
    0xa0aa0007, 0x02000001, 0x80020002, 0xa0ff0007, 0x02000001, 0x80020001,
    0xa0ff0007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40800, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40800, 0x04000012, 0x800f0003, 0x80550000,
    0x80e40002, 0x80e40001, 0x0200000f, 0x80010000, 0x80000003, 0x0200000f,
    0x80020000, 0x80550003, 0x0200000f, 0x80040000, 0x80aa0003, 0x03000005,
    0x80070000, 0x80e40000, 0xa0000008, 0x0200000e, 0x80010001, 0x80000000,
    0x0200000e, 0x80020001, 0x80550000, 0x0200000e, 0x80040001, 0x80aa0000,
    0x04000004, 0x80070003, 0x80e40001, 0xa0550008, 0xa0aa0008, 0x03000005,
    0x800f0000, 0x80e40003, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial24 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0, 0.5, -1
    def c4, 1, 0.5, 0.0625, 0.03125
    def c5, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.z, c3.x
    mov r0.xy, t1
    dp3 r0.w, r0, c17
    mul r0.w, r0.w, r0.w
    mul r0.w, r0.w, c18.y
    dp3 r0.x, r0, c16
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.w
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mov r0.z, c18.z
    mad r0.y, r0.x, r0.z, -c0.x
    mul_sat r0.y, r0.y, c0.y
    mad r0.w, r0.x, r0.z, -c1.x
    mul_sat r0.w, r0.w, c1.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c2.x
    mul_sat r0.w, r0.w, c2.y
    add r0.y, r0.y, r0.w
    frc r0.w, r0.y
    add r0.y, r0.y, -r0.w
    add r1.w, r0.y, c3.x
    mad r1.x, r1.w, c4.z, c4.w
    mul r1.z, r0.x, c18.z
    mad r1.w, r0.x, r0.z, c3.w
    mad r0.x, r0.y, c4.z, c4.w
    mov r0.y, c3.z
    mov r1.y, c3.z
    mov r2.xy, c4
    mov r3.xy, c3.yzxw
    texld r4, r0, s1
    texld r5, r1, s1
    texld r2, r2, s1
    texld r3, r3, s1
    texld r6, t0, s0
    lrp r7, r0.w, r5, r4
    cmp r0, r1.w, r2, r7
    cmp r0, -r1.z, r3, r0
    log r1.x, r0.x
    log r1.y, r0.y
    log r1.z, r0.z
    mul r1.xyz, r1, c5.x
    exp r2.x, r1.x
    exp r2.y, r1.y
    exp r2.z, r1.z
    mad r0.xyz, r2, c5.y, c5.z
    mul r0, r6.w, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 50 instruction slots used (5 texture, 45 arithmetic)
#endif

const DWORD radial24[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020003,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0004,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x05000051, 0xa00f0005,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80040000, 0xa0000003, 0x02000001, 0x80030000,
    0xb0e40001, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000005,
    0x80080000, 0x80ff0000, 0x80ff0000, 0x03000005, 0x80080000, 0x80ff0000,
    0xa0550012, 0x03000008, 0x80010000, 0x80e40000, 0xa0e40010, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80ff0000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x02000001, 0x80040000, 0xa0aa0012, 0x04000004, 0x80020000,
    0x80000000, 0x80aa0000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000001,
    0x03000005, 0x80180000, 0x80ff0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000,
    0xa1000002, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550002, 0x03000002,
    0x80020000, 0x80550000, 0x80ff0000, 0x02000013, 0x80080000, 0x80550000,
    0x03000002, 0x80020000, 0x80550000, 0x81ff0000, 0x03000002, 0x80080001,
    0x80550000, 0xa0000003, 0x04000004, 0x80010001, 0x80ff0001, 0xa0aa0004,
    0xa0ff0004, 0x03000005, 0x80040001, 0x80000000, 0xa0aa0012, 0x04000004,
    0x80080001, 0x80000000, 0x80aa0000, 0xa0ff0003, 0x04000004, 0x80010000,
    0x80550000, 0xa0aa0004, 0xa0ff0004, 0x02000001, 0x80020000, 0xa0aa0003,
    0x02000001, 0x80020001, 0xa0aa0003, 0x02000001, 0x80030002, 0xa0e40004,
    0x02000001, 0x80030003, 0xa0c90003, 0x03000042, 0x800f0004, 0x80e40000,
    0xa0e40801, 0x03000042, 0x800f0005, 0x80e40001, 0xa0e40801, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0003, 0x80e40003,
    0xa0e40801, 0x03000042, 0x800f0006, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0007, 0x80ff0000, 0x80e40005, 0x80e40004, 0x04000058, 0x800f0000,
    0x80ff0001, 0x80e40002, 0x80e40007, 0x04000058, 0x800f0000, 0x81aa0001,
    0x80e40003, 0x80e40000, 0x0200000f, 0x80010001, 0x80000000, 0x0200000f,
    0x80020001, 0x80550000, 0x0200000f, 0x80040001, 0x80aa0000, 0x03000005,
    0x80070001, 0x80e40001, 0xa0000005, 0x0200000e, 0x80010002, 0x80000001,
    0x0200000e, 0x80020002, 0x80550001, 0x0200000e, 0x80040002, 0x80aa0001,
    0x04000004, 0x80070000, 0x80e40002, 0xa0550005, 0xa0aa0005, 0x03000005,
    0x800f0000, 0x80ff0006, 0x80e40000, 0x03000005, 0x800f0000, 0x80e40000,
    0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial25 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0.5, -0.5, 2
    def c4, 0.0625, 0.03125, 0.416667014, 0
    def c5, 1.05499995, -0.0549999997, 0, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    mul r0.x, r0.x, c3.y
    frc r0.x, r0.x
    add r0.x, r0.x, c3.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c3.w, c3.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c4.x, c4.y
    mad r2.x, r0.z, c4.x, c4.y
    mov r2.y, c3.y
    mov r1.y, c3.y
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    log r0.x, r4.x
    log r0.y, r4.y
    log r0.z, r4.z
    mul r0.xyz, r0, c4.z
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r4.xyz, r1, c5.x, c5.y
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 47 instruction slots used (3 texture, 44 arithmetic)
#endif

const DWORD radial25[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020003,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0004,
    0x3d800000, 0x3d000000, 0x3ed55561, 0x00000000, 0x05000051, 0xa00f0005,
    0x3f870a3d, 0xbd6147ae, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x03000005,
    0x80010000, 0x80000000, 0xa0550003, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0003, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0003, 0xa0000003,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000002, 0x80010000, 0x80000000, 0xa1000002, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550001, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550002, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000003, 0x04000004, 0x80010001, 0x80000000, 0xa0000004, 0xa0550004,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000004, 0xa0550004, 0x02000001,
    0x80020002, 0xa0550003, 0x02000001, 0x80020001, 0xa0550003, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0004, 0x80550000, 0x80e40002, 0x80e40001, 0x0200000f, 0x80010000,
    0x80000004, 0x0200000f, 0x80020000, 0x80550004, 0x0200000f, 0x80040000,
    0x80aa0004, 0x03000005, 0x80070000, 0x80e40000, 0xa0aa0004, 0x0200000e,
    0x80010001, 0x80000000, 0x0200000e, 0x80020001, 0x80550000, 0x0200000e,
    0x80040001, 0x80aa0000, 0x04000004, 0x80070004, 0x80e40001, 0xa0000005,
    0xa0550005, 0x03000005, 0x800f0000, 0x80ff0003, 0x80e40004, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial26 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[4];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       3
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c3, 1, 0.0625, 0.03125, 0.5
    def c4, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c3.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    add r0.x, r0.x, -c2.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c2.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c3.x
    mad r1.x, r0.x, c3.y, c3.z
    mad r2.x, r0.z, c3.y, c3.z
    mov r2.y, c3.w
    mov r1.y, c3.w
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    log r0.x, r4.x
    log r0.y, r4.y
    log r0.z, r4.z
    mul r0.xyz, r0, c4.x
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r4.xyz, r1, c4.y, c4.z
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 43 instruction slots used (3 texture, 40 arithmetic)
#endif

const DWORD radial26[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020003,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000004, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0003,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x05000051, 0xa00f0004,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000003, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000002, 0x80010000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550002,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000003, 0x04000004, 0x80010001, 0x80000000,
    0xa0550003, 0xa0aa0003, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550003,
    0xa0aa0003, 0x02000001, 0x80020002, 0xa0ff0003, 0x02000001, 0x80020001,
    0xa0ff0003, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000,
    0xa0e40800, 0x04000012, 0x800f0004, 0x80550000, 0x80e40002, 0x80e40001,
    0x0200000f, 0x80010000, 0x80000004, 0x0200000f, 0x80020000, 0x80550004,
    0x0200000f, 0x80040000, 0x80aa0004, 0x03000005, 0x80070000, 0x80e40000,
    0xa0000004, 0x0200000e, 0x80010001, 0x80000000, 0x0200000e, 0x80020001,
    0x80550000, 0x0200000e, 0x80040001, 0x80aa0000, 0x04000004, 0x80070004,
    0x80e40001, 0xa0550004, 0xa0aa0004, 0x03000005, 0x800f0000, 0x80ff0003,
    0x80e40004, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001,
    0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial28 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0, 0.5, -1
    def c8, 1, 0.5, 0.0625, 0.03125
    def c9, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.z, c7.x
    mov r0.xy, t1
    dp3 r0.w, r0, c17
    mul r0.w, r0.w, r0.w
    mul r0.w, r0.w, c18.y
    dp3 r0.x, r0, c16
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.w
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mov r0.z, c18.z
    mad r0.y, r0.x, r0.z, -c0.x
    mul_sat r0.y, r0.y, c0.y
    mad r0.w, r0.x, r0.z, -c1.x
    mul_sat r0.w, r0.w, c1.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c2.x
    mul_sat r0.w, r0.w, c2.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c3.x
    mul_sat r0.w, r0.w, c3.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c4.x
    mul_sat r0.w, r0.w, c4.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c5.x
    mul_sat r0.w, r0.w, c5.y
    add r0.y, r0.y, r0.w
    mad r0.w, r0.x, r0.z, -c6.x
    mul_sat r0.w, r0.w, c6.y
    add r0.y, r0.y, r0.w
    frc r0.w, r0.y
    add r0.y, r0.y, -r0.w
    add r1.w, r0.y, c7.x
    mad r1.x, r1.w, c8.z, c8.w
    mul r1.z, r0.x, c18.z
    mad r1.w, r0.x, r0.z, c7.w
    mad r0.x, r0.y, c8.z, c8.w
    mov r0.y, c7.z
    mov r1.y, c7.z
    mov r2.xy, c8
    mov r3.xy, c7.yzxw
    texld r4, r0, s1
    texld r5, r1, s1
    texld r2, r2, s1
    texld r3, r3, s1
    texld r6, t0, s0
    lrp r7, r0.w, r5, r4
    cmp r0, r1.w, r2, r7
    cmp r0, -r1.z, r3, r0
    log r1.x, r0.x
    log r1.y, r0.y
    log r1.z, r0.z
    mul r1.xyz, r1, c9.x
    exp r2.x, r1.x
    exp r2.y, r1.y
    exp r2.z, r1.z
    mad r0.xyz, r2, c9.y, c9.z
    mul r0, r6.w, r0
    mul r0, r0, v0
    mov oC0, r0

// approximately 62 instruction slots used (5 texture, 57 arithmetic)
#endif

const DWORD radial28[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020007,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x00000000, 0x3f000000, 0xbf800000, 0x05000051, 0xa00f0008,
    0x3f800000, 0x3f000000, 0x3d800000, 0x3d000000, 0x05000051, 0xa00f0009,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80040000, 0xa0000007, 0x02000001, 0x80030000,
    0xb0e40001, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000005,
    0x80080000, 0x80ff0000, 0x80ff0000, 0x03000005, 0x80080000, 0x80ff0000,
    0xa0550012, 0x03000008, 0x80010000, 0x80e40000, 0xa0e40010, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80ff0000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x02000001, 0x80040000, 0xa0aa0012, 0x04000004, 0x80020000,
    0x80000000, 0x80aa0000, 0xa1000000, 0x03000005, 0x80120000, 0x80550000,
    0xa0550000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000001,
    0x03000005, 0x80180000, 0x80ff0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000, 0x80aa0000,
    0xa1000002, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550002, 0x03000002,
    0x80020000, 0x80550000, 0x80ff0000, 0x04000004, 0x80080000, 0x80000000,
    0x80aa0000, 0xa1000003, 0x03000005, 0x80180000, 0x80ff0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80ff0000, 0x04000004, 0x80080000,
    0x80000000, 0x80aa0000, 0xa1000004, 0x03000005, 0x80180000, 0x80ff0000,
    0xa0550004, 0x03000002, 0x80020000, 0x80550000, 0x80ff0000, 0x04000004,
    0x80080000, 0x80000000, 0x80aa0000, 0xa1000005, 0x03000005, 0x80180000,
    0x80ff0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80ff0000,
    0x04000004, 0x80080000, 0x80000000, 0x80aa0000, 0xa1000006, 0x03000005,
    0x80180000, 0x80ff0000, 0xa0550006, 0x03000002, 0x80020000, 0x80550000,
    0x80ff0000, 0x02000013, 0x80080000, 0x80550000, 0x03000002, 0x80020000,
    0x80550000, 0x81ff0000, 0x03000002, 0x80080001, 0x80550000, 0xa0000007,
    0x04000004, 0x80010001, 0x80ff0001, 0xa0aa0008, 0xa0ff0008, 0x03000005,
    0x80040001, 0x80000000, 0xa0aa0012, 0x04000004, 0x80080001, 0x80000000,
    0x80aa0000, 0xa0ff0007, 0x04000004, 0x80010000, 0x80550000, 0xa0aa0008,
    0xa0ff0008, 0x02000001, 0x80020000, 0xa0aa0007, 0x02000001, 0x80020001,
    0xa0aa0007, 0x02000001, 0x80030002, 0xa0e40008, 0x02000001, 0x80030003,
    0xa0c90007, 0x03000042, 0x800f0004, 0x80e40000, 0xa0e40801, 0x03000042,
    0x800f0005, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0002, 0x80e40002,
    0xa0e40801, 0x03000042, 0x800f0003, 0x80e40003, 0xa0e40801, 0x03000042,
    0x800f0006, 0xb0e40000, 0xa0e40800, 0x04000012, 0x800f0007, 0x80ff0000,
    0x80e40005, 0x80e40004, 0x04000058, 0x800f0000, 0x80ff0001, 0x80e40002,
    0x80e40007, 0x04000058, 0x800f0000, 0x81aa0001, 0x80e40003, 0x80e40000,
    0x0200000f, 0x80010001, 0x80000000, 0x0200000f, 0x80020001, 0x80550000,
    0x0200000f, 0x80040001, 0x80aa0000, 0x03000005, 0x80070001, 0x80e40001,
    0xa0000009, 0x0200000e, 0x80010002, 0x80000001, 0x0200000e, 0x80020002,
    0x80550001, 0x0200000e, 0x80040002, 0x80aa0001, 0x04000004, 0x80070000,
    0x80e40002, 0xa0550009, 0xa0aa0009, 0x03000005, 0x800f0000, 0x80ff0006,
    0x80e40000, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001,
    0x800f0800, 0x80e40000, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial29 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0.5, -0.5, 2
    def c8, 0.0625, 0.03125, 0.416667014, 0
    def c9, 1.05499995, -0.0549999997, 0, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c7.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    mul r0.x, r0.x, c7.y
    frc r0.x, r0.x
    add r0.x, r0.x, c7.z
    abs r0.x, r0.x
    mad r0.x, r0.x, -c7.w, c7.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c8.x, c8.y
    mad r2.x, r0.z, c8.x, c8.y
    mov r2.y, c7.y
    mov r1.y, c7.y
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    log r0.x, r4.x
    log r0.y, r4.y
    log r0.z, r4.z
    mul r0.xyz, r0, c8.z
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r4.xyz, r1, c9.x, c9.y
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 59 instruction slots used (3 texture, 56 arithmetic)
#endif

const DWORD radial29[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020007,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3f000000, 0xbf000000, 0x40000000, 0x05000051, 0xa00f0008,
    0x3d800000, 0x3d000000, 0x3ed55561, 0x00000000, 0x05000051, 0xa00f0009,
    0x3f870a3d, 0xbd6147ae, 0x00000000, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x03000005,
    0x80010000, 0x80000000, 0xa0550007, 0x02000013, 0x80010000, 0x80000000,
    0x03000002, 0x80010000, 0x80000000, 0xa0aa0007, 0x02000023, 0x80010000,
    0x80000000, 0x04000004, 0x80010000, 0x80000000, 0xa1ff0007, 0xa0000007,
    0x03000002, 0x80020000, 0x80000000, 0xa1000000, 0x03000005, 0x80120000,
    0x80550000, 0xa0550000, 0x03000002, 0x80040000, 0x80000000, 0xa1000001,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550001, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000002,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550002, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000003,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550003, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000004,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550004, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000002, 0x80040000, 0x80000000, 0xa1000005,
    0x03000002, 0x80010000, 0x80000000, 0xa1000006, 0x03000005, 0x80140000,
    0x80aa0000, 0xa0550005, 0x03000002, 0x80020000, 0x80550000, 0x80aa0000,
    0x03000005, 0x80110000, 0x80000000, 0xa0550006, 0x03000002, 0x80010000,
    0x80550000, 0x80000000, 0x02000013, 0x80020000, 0x80000000, 0x03000002,
    0x80010000, 0x80000000, 0x81550000, 0x03000002, 0x80040000, 0x80000000,
    0xa0000007, 0x04000004, 0x80010001, 0x80000000, 0xa0000008, 0xa0550008,
    0x04000004, 0x80010002, 0x80aa0000, 0xa0000008, 0xa0550008, 0x02000001,
    0x80020002, 0xa0550007, 0x02000001, 0x80020001, 0xa0550007, 0x03000042,
    0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042, 0x800f0001, 0x80e40001,
    0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000, 0xa0e40800, 0x04000012,
    0x800f0004, 0x80550000, 0x80e40002, 0x80e40001, 0x0200000f, 0x80010000,
    0x80000004, 0x0200000f, 0x80020000, 0x80550004, 0x0200000f, 0x80040000,
    0x80aa0004, 0x03000005, 0x80070000, 0x80e40000, 0xa0aa0008, 0x0200000e,
    0x80010001, 0x80000000, 0x0200000e, 0x80020001, 0x80550000, 0x0200000e,
    0x80040001, 0x80aa0000, 0x04000004, 0x80070004, 0x80e40001, 0xa0000009,
    0xa0550009, 0x03000005, 0x800f0000, 0x80ff0003, 0x80e40004, 0x03000005,
    0x800f0000, 0x80e40000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000,
    0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn radial30 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D colors;
//   float2 fractions[8];
//   float3 m0;
//   float3 m1;
//   sampler2D mask;
//   float3 precalc;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   fractions    c0       7
//   m0           c16      1
//   m1           c17      1
//   precalc      c18      1
//   mask         s0       1
//   colors       s1       1
//

    ps_2_0
    def c7, 1, 0.0625, 0.03125, 0.5
    def c8, 0.416667014, 1.05499995, -0.0549999997, 0
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dcl_2d s0
    dcl_2d s1
    mov r0.xy, t1
    mov r0.z, c7.x
    dp3 r0.w, r0, c17
    dp3 r0.x, r0, c16
    mul r0.y, r0.w, r0.w
    mul r0.y, r0.y, c18.y
    add r0.x, r0.x, -c18.x
    mad r0.y, r0.x, r0.x, r0.y
    rsq r0.y, r0.y
    rcp r0.y, r0.y
    mad r0.x, c18.x, r0.x, r0.y
    mul r0.x, r0.x, c18.z
    frc r0.x, r0.x
    add r0.y, r0.x, -c0.x
    mul_sat r0.y, r0.y, c0.y
    add r0.z, r0.x, -c1.x
    mul_sat r0.z, r0.z, c1.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c2.x
    mul_sat r0.z, r0.z, c2.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c3.x
    mul_sat r0.z, r0.z, c3.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c4.x
    mul_sat r0.z, r0.z, c4.y
    add r0.y, r0.y, r0.z
    add r0.z, r0.x, -c5.x
    add r0.x, r0.x, -c6.x
    mul_sat r0.z, r0.z, c5.y
    add r0.y, r0.y, r0.z
    mul_sat r0.x, r0.x, c6.y
    add r0.x, r0.y, r0.x
    frc r0.y, r0.x
    add r0.x, r0.x, -r0.y
    add r0.z, r0.x, c7.x
    mad r1.x, r0.x, c7.y, c7.z
    mad r2.x, r0.z, c7.y, c7.z
    mov r2.y, c7.w
    mov r1.y, c7.w
    texld r2, r2, s1
    texld r1, r1, s1
    texld r3, t0, s0
    lrp r4, r0.y, r2, r1
    log r0.x, r4.x
    log r0.y, r4.y
    log r0.z, r4.z
    mul r0.xyz, r0, c8.x
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mad r4.xyz, r1, c8.y, c8.z
    mul r0, r3.w, r4
    mul r0, r0, v0
    mov oC0, r0

// approximately 55 instruction slots used (3 texture, 52 arithmetic)
#endif

const DWORD radial30[] =
{
    0xffff0200, 0x004afffe, 0x42415443, 0x0000001c, 0x000000f3, 0xffff0200,
    0x00000006, 0x0000001c, 0x20000100, 0x000000ec, 0x00000094, 0x00010003,
    0x00060001, 0x0000009c, 0x00000000, 0x000000ac, 0x00000002, 0x00020007,
    0x000000b8, 0x00000000, 0x000000c8, 0x00100002, 0x00420001, 0x000000cc,
    0x00000000, 0x000000dc, 0x00110002, 0x00460001, 0x000000cc, 0x00000000,
    0x000000df, 0x00000003, 0x00020001, 0x0000009c, 0x00000000, 0x000000e4,
    0x00120002, 0x004a0001, 0x000000cc, 0x00000000, 0x6f6c6f63, 0xab007372,
    0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x63617266, 0x6e6f6974,
    0xabab0073, 0x00030001, 0x00020001, 0x00000008, 0x00000000, 0xab00306d,
    0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x6d00316d, 0x006b7361,
    0x63657270, 0x00636c61, 0x325f7370, 0x4d00305f, 0x6f726369, 0x74666f73,
    0x29522820, 0x534c4820, 0x6853204c, 0x72656461, 0x6d6f4320, 0x656c6970,
    0x2e392072, 0x392e3931, 0x322e3934, 0x00313131, 0x05000051, 0xa00f0007,
    0x3f800000, 0x3d800000, 0x3d000000, 0x3f000000, 0x05000051, 0xa00f0008,
    0x3ed55561, 0x3f870a3d, 0xbd6147ae, 0x00000000, 0x0200001f, 0x80000000,
    0xb0030000, 0x0200001f, 0x80000000, 0xb0030001, 0x0200001f, 0x80000000,
    0x900f0000, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f, 0x90000000,
    0xa00f0801, 0x02000001, 0x80030000, 0xb0e40001, 0x02000001, 0x80040000,
    0xa0000007, 0x03000008, 0x80080000, 0x80e40000, 0xa0e40011, 0x03000008,
    0x80010000, 0x80e40000, 0xa0e40010, 0x03000005, 0x80020000, 0x80ff0000,
    0x80ff0000, 0x03000005, 0x80020000, 0x80550000, 0xa0550012, 0x03000002,
    0x80010000, 0x80000000, 0xa1000012, 0x04000004, 0x80020000, 0x80000000,
    0x80000000, 0x80550000, 0x02000007, 0x80020000, 0x80550000, 0x02000006,
    0x80020000, 0x80550000, 0x04000004, 0x80010000, 0xa0000012, 0x80000000,
    0x80550000, 0x03000005, 0x80010000, 0x80000000, 0xa0aa0012, 0x02000013,
    0x80010000, 0x80000000, 0x03000002, 0x80020000, 0x80000000, 0xa1000000,
    0x03000005, 0x80120000, 0x80550000, 0xa0550000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000001, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550001,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000002, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550002,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000003, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550003,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000004, 0x03000005, 0x80140000, 0x80aa0000, 0xa0550004,
    0x03000002, 0x80020000, 0x80550000, 0x80aa0000, 0x03000002, 0x80040000,
    0x80000000, 0xa1000005, 0x03000002, 0x80010000, 0x80000000, 0xa1000006,
    0x03000005, 0x80140000, 0x80aa0000, 0xa0550005, 0x03000002, 0x80020000,
    0x80550000, 0x80aa0000, 0x03000005, 0x80110000, 0x80000000, 0xa0550006,
    0x03000002, 0x80010000, 0x80550000, 0x80000000, 0x02000013, 0x80020000,
    0x80000000, 0x03000002, 0x80010000, 0x80000000, 0x81550000, 0x03000002,
    0x80040000, 0x80000000, 0xa0000007, 0x04000004, 0x80010001, 0x80000000,
    0xa0550007, 0xa0aa0007, 0x04000004, 0x80010002, 0x80aa0000, 0xa0550007,
    0xa0aa0007, 0x02000001, 0x80020002, 0xa0ff0007, 0x02000001, 0x80020001,
    0xa0ff0007, 0x03000042, 0x800f0002, 0x80e40002, 0xa0e40801, 0x03000042,
    0x800f0001, 0x80e40001, 0xa0e40801, 0x03000042, 0x800f0003, 0xb0e40000,
    0xa0e40800, 0x04000012, 0x800f0004, 0x80550000, 0x80e40002, 0x80e40001,
    0x0200000f, 0x80010000, 0x80000004, 0x0200000f, 0x80020000, 0x80550004,
    0x0200000f, 0x80040000, 0x80aa0004, 0x03000005, 0x80070000, 0x80e40000,
    0xa0000008, 0x0200000e, 0x80010001, 0x80000000, 0x0200000e, 0x80020001,
    0x80550000, 0x0200000e, 0x80040001, 0x80aa0000, 0x04000004, 0x80070004,
    0x80e40001, 0xa0550008, 0xa0aa0008, 0x03000005, 0x800f0000, 0x80ff0003,
    0x80e40004, 0x03000005, 0x800f0000, 0x80e40000, 0x90e40000, 0x02000001,
    0x800f0800, 0x80e40000, 0x0000ffff
};
const DWORD *radialShaders[] =
{
    radial0,
    radial1,
    radial2,
    NULL,
    radial4,
    radial5,
    radial6,
    NULL,
    radial8,
    radial9,
    radial10,
    NULL,
    radial12,
    radial13,
    radial14,
    NULL,
    radial16,
    radial17,
    radial18,
    NULL,
    radial20,
    radial21,
    radial22,
    NULL,
    radial24,
    radial25,
    radial26,
    NULL,
    radial28,
    radial29,
    radial30,
    NULL,
};

#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_0 /Vn lcdtext0 /Fh tmp.h tmp.hlsl
//
//
// Parameters:
//
//   sampler2D dstTex;
//   float3 gamma;
//   sampler2D glyphTex;
//   float3 invgamma;
//   float3 srcAdj;
//
//
// Registers:
//
//   Name         Reg   Size
//   ------------ ----- ----
//   srcAdj       c0       1
//   invgamma     c1       1
//   gamma        c2       1
//   glyphTex     s0       1
//   dstTex       s1       1
//

    ps_2_0
    def c3, -1, 0, 1, 0
    dcl t0.xy
    dcl t1.xy
    dcl_2d s0
    dcl_2d s1
    texld r0, t0, s0
    dp3 r0.w, r0, r0
    cmp r1, -r0.w, c3.x, c3.y
    texkill r1
    texld r1, t1, s1
    log r2.x, r1.x
    log r2.y, r1.y
    log r2.z, r1.z
    mul r1.xyz, r2, c1
    exp r2.x, r1.x
    exp r2.y, r1.y
    exp r2.z, r1.z
    lrp r1.xyz, r0, c0, r2
    log r0.x, r1.x
    log r0.y, r1.y
    log r0.z, r1.z
    mul r0.xyz, r0, c2
    exp r1.x, r0.x
    exp r1.y, r0.y
    exp r1.z, r0.z
    mov r1.w, c3.z
    mov oC0, r1

// approximately 22 instruction slots used (2 texture, 20 arithmetic)
#endif

const DWORD lcdtext0[] =
{
    0xffff0200, 0x0042fffe, 0x42415443, 0x0000001c, 0x000000d0, 0xffff0200,
    0x00000005, 0x0000001c, 0x20000100, 0x000000c9, 0x00000080, 0x00010003,
    0x00060001, 0x00000088, 0x00000000, 0x00000098, 0x00020002, 0x000a0001,
    0x000000a0, 0x00000000, 0x000000b0, 0x00000003, 0x00020001, 0x00000088,
    0x00000000, 0x000000b9, 0x00010002, 0x00060001, 0x000000a0, 0x00000000,
    0x000000c2, 0x00000002, 0x00020001, 0x000000a0, 0x00000000, 0x54747364,
    0xab007865, 0x000c0004, 0x00010001, 0x00000001, 0x00000000, 0x6d6d6167,
    0xabab0061, 0x00030001, 0x00030001, 0x00000001, 0x00000000, 0x70796c67,
    0x78655468, 0x766e6900, 0x6d6d6167, 0x72730061, 0x6a644163, 0x5f737000,
    0x00305f32, 0x7263694d, 0x666f736f, 0x52282074, 0x4c482029, 0x53204c53,
    0x65646168, 0x6f432072, 0x6c69706d, 0x39207265, 0x2e39312e, 0x2e393439,
    0x31313132, 0xababab00, 0x05000051, 0xa00f0003, 0xbf800000, 0x80000000,
    0x3f800000, 0x00000000, 0x0200001f, 0x80000000, 0xb0030000, 0x0200001f,
    0x80000000, 0xb0030001, 0x0200001f, 0x90000000, 0xa00f0800, 0x0200001f,
    0x90000000, 0xa00f0801, 0x03000042, 0x800f0000, 0xb0e40000, 0xa0e40800,
    0x03000008, 0x80080000, 0x80e40000, 0x80e40000, 0x04000058, 0x800f0001,
    0x81ff0000, 0xa0000003, 0xa0550003, 0x01000041, 0x800f0001, 0x03000042,
    0x800f0001, 0xb0e40001, 0xa0e40801, 0x0200000f, 0x80010002, 0x80000001,
    0x0200000f, 0x80020002, 0x80550001, 0x0200000f, 0x80040002, 0x80aa0001,
    0x03000005, 0x80070001, 0x80e40002, 0xa0e40001, 0x0200000e, 0x80010002,
    0x80000001, 0x0200000e, 0x80020002, 0x80550001, 0x0200000e, 0x80040002,
    0x80aa0001, 0x04000012, 0x80070001, 0x80e40000, 0xa0e40000, 0x80e40002,
    0x0200000f, 0x80010000, 0x80000001, 0x0200000f, 0x80020000, 0x80550001,
    0x0200000f, 0x80040000, 0x80aa0001, 0x03000005, 0x80070000, 0x80e40000,
    0xa0e40002, 0x0200000e, 0x80010001, 0x80000000, 0x0200000e, 0x80020001,
    0x80550000, 0x0200000e, 0x80040001, 0x80aa0000, 0x02000001, 0x80080001,
    0xa0aa0003, 0x02000001, 0x800f0800, 0x80e40001, 0x0000ffff
};
#if 0
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.19.949.2111
//
//   fxc /T ps_2_a /Vn aapgram0 /Fh tmp.h tmp.hlsl
//
    ps_2_x
    dcl t0.xy
    dcl t1.xy
    dcl v0
    dsx r0.xy, t1.yxzw
    add r0.xy, r0, t1.yxzw
    min r1.xy, r0, t1.yxzw
    dsy r0.zw, t1.xyyx
    add r1.zw, r0, t1.xyyx
    add r0.zw, r0.xyxy, r0
    max r2.xy, t1.yxzw, r0
    min r0.xy, r1.zwzw, r1
    max r3.xy, r2, r1.zwzw
    min r1.xy, r0.zwzw, r0
    max r1.zw, r3.xyxy, r0
    mov_sat r0.xy, r1
    add r0.zw, -r1.xyxy, r1
    mov_sat r1.zw, r1
    add r0.xy, -r0, r1.zwzw
    mul r0.xy, r0.ywzw, r0.xzzw
    rcp r0.y, r0.y
    mul r0.x, r0.x, r0.y
    dsx r0.yz, t0.xyxw
    add r0.yz, r0, t0.xyxw
    min r1.xy, r0.yzzw, t0.yxzw
    dsy r1.zw, t0.xyyx
    add r2.xy, r1.zwzw, t0.yxzw
    add r1.zw, r0.xyyz, r1
    max r2.zw, t0.xyyx, r0.xyyz
    min r0.yz, r2.xxyw, r1.xxyw
    max r1.xy, r2.zwzw, r2
    min r2.xy, r1.zwzw, r0.yzzw
    max r0.yz, r1.xxyw, r1.xzww
    mov_sat r1.xy, r2
    add r1.zw, -r2.xyxy, r0.xyyz
    mov_sat r0.yz, r0
    add r0.yz, -r1.xxyw, r0
    mul r0.y, r0.z, r0.y
    mul r0.z, r1.w, r1.z
    rcp r0.z, r0.z
    mad r0.x, r0.y, r0.z, -r0.x
    mul r0, r0.x, v0
    mov oC0, r0

// approximately 43 instruction slots used
#endif

const DWORD aapgram0[] =
{
    0xffff0201, 0x0016fffe, 0x42415443, 0x0000001c, 0x00000023, 0xffff0201,
    0x00000000, 0x00000000, 0x20000100, 0x0000001c, 0x325f7370, 0x4d00615f,
    0x6f726369, 0x74666f73, 0x29522820, 0x534c4820, 0x6853204c, 0x72656461,
    0x6d6f4320, 0x656c6970, 0x2e392072, 0x392e3931, 0x322e3934, 0x00313131,
    0x0200001f, 0x80000000, 0xb0030000, 0x0200001f, 0x80000000, 0xb0030001,
    0x0200001f, 0x80000000, 0x900f0000, 0x0200005b, 0x80030000, 0xb0e10001,
    0x03000002, 0x80030000, 0x80e40000, 0xb0e10001, 0x0300000a, 0x80030001,
    0x80e40000, 0xb0e10001, 0x0200005c, 0x800c0000, 0xb0140001, 0x03000002,
    0x800c0001, 0x80e40000, 0xb0140001, 0x03000002, 0x800c0000, 0x80440000,
    0x80e40000, 0x0300000b, 0x80030002, 0xb0e10001, 0x80e40000, 0x0300000a,
    0x80030000, 0x80ee0001, 0x80e40001, 0x0300000b, 0x80030003, 0x80e40002,
    0x80ee0001, 0x0300000a, 0x80030001, 0x80ee0000, 0x80e40000, 0x0300000b,
    0x800c0001, 0x80440003, 0x80e40000, 0x02000001, 0x80130000, 0x80e40001,
    0x03000002, 0x800c0000, 0x81440001, 0x80e40001, 0x02000001, 0x801c0001,
    0x80e40001, 0x03000002, 0x80030000, 0x81e40000, 0x80ee0001, 0x03000005,
    0x80030000, 0x80ed0000, 0x80e80000, 0x02000006, 0x80020000, 0x80550000,
    0x03000005, 0x80010000, 0x80000000, 0x80550000, 0x0200005b, 0x80060000,
    0xb0c40000, 0x03000002, 0x80060000, 0x80e40000, 0xb0c40000, 0x0300000a,
    0x80030001, 0x80e90000, 0xb0e10000, 0x0200005c, 0x800c0001, 0xb0140000,
    0x03000002, 0x80030002, 0x80ee0001, 0xb0e10000, 0x03000002, 0x800c0001,
    0x80940000, 0x80e40001, 0x0300000b, 0x800c0002, 0xb0140000, 0x80940000,
    0x0300000a, 0x80060000, 0x80d00002, 0x80d00001, 0x0300000b, 0x80030001,
    0x80ee0002, 0x80e40002, 0x0300000a, 0x80030002, 0x80ee0001, 0x80e90000,
    0x0300000b, 0x80060000, 0x80d00001, 0x80f80001, 0x02000001, 0x80130001,
    0x80e40002, 0x03000002, 0x800c0001, 0x81440002, 0x80940000, 0x02000001,
    0x80160000, 0x80e40000, 0x03000002, 0x80060000, 0x81d00001, 0x80e40000,
    0x03000005, 0x80020000, 0x80aa0000, 0x80550000, 0x03000005, 0x80040000,
    0x80ff0001, 0x80aa0001, 0x02000006, 0x80040000, 0x80aa0000, 0x04000004,
    0x80010000, 0x80550000, 0x80aa0000, 0x81000000, 0x03000005, 0x800f0000,
    0x80000000, 0x90e40000, 0x02000001, 0x800f0800, 0x80e40000, 0x0000ffff
};
